addProperty

Adds a custom property to the event.

If the total added properties exceed MAX_TOTAL_PROPERTIES_SIZE in size it will cause the event to be invalid.

Return

The custom event builder.

Parameters

name

The property name.

value

A property value.


fun addProperty(@Size(min = 1) name: String, @Size(min = 1) value: String): CustomEvent.Builder
fun addProperty(@Size(min = 1) name: String, value: Int): CustomEvent.Builder
fun addProperty(@Size(min = 1) name: String, value: Long): CustomEvent.Builder

Adds a custom property to the event.

If the total added properties exceed MAX_TOTAL_PROPERTIES_SIZE in size it will cause the event to be invalid.

Return

The custom event builder.

Parameters

name

The property name.

value

The property value.


fun addProperty(@Size(min = 1) name: String, value: Double): CustomEvent.Builder

Adds a custom property to the event.

If the total number of properties exceed MAX_TOTAL_PROPERTIES_SIZE it will cause the event to be invalid.

Return

The custom event builder.

Parameters

name

The property name.

value

The property value.

Throws

if the value is infinite or not a number


fun addProperty(@Size(min = 1) name: String, value: Boolean): CustomEvent.Builder

Adds a custom property to the event.

If the total number of properties exceed MAX_TOTAL_PROPERTIES_SIZE it will cause the event to be invalid.

Return

The custom event builder.

Parameters

name

The property name.

value

The property value.