EvaluateDataEventSchema

@Serializable
@SerialName(value = "EvaluateData")
data class EvaluateDataEventSchema(val id: String, val trigger: EventTrigger, val events: SerializableImmutableList<EventSchema>?, val expression: EvaluateDataEventSchema.Expression) : EventSchema

Evaluates the boolean expression and branches on its result. Runs on the IO dispatcher.

Expression composes And, Or and Not over leaf data expressions. Each leaf reads a value — either the event's own incomingData or a reading from a data source (inline map, plain and segmented local databases, application/screen/navigation data holders, or a tile's produced value) — and applies an operation to it: null checks, string, int, long, float, double, boolean, map, list and local-date-time comparisons. An operation whose value has the wrong runtime type yields false rather than raising.

incomingData consumed: read by any IncomingData leaf in expression, and forwarded unchanged to whichever trigger fires.

Triggers fired:

  • OnSuccessEventTrigger — when the expression evaluates to true; incomingData is forwarded.

  • OnFailureEventTrigger — when the expression evaluates to false, with incomingData forwarded; and also when evaluation throws, in which case the Throwable is passed instead and the error is logged.

Constructors

Link copied to clipboard

Types

Link copied to clipboard
@Serializable
sealed interface Expression

Properties

Link copied to clipboard
@SerialName(value = "events")
open override val events: SerializableImmutableList<EventSchema>?

This event's own children — each declaring, via its own trigger, which of this event's outgoing triggers runs it. null when this event declares no children.

Link copied to clipboard
@SerialName(value = "expression")
val expression: EvaluateDataEventSchema.Expression
Link copied to clipboard
@SerialName(value = "id")
open override val id: String

Unique identifier — how TriggerEvent/UpdateEvents address this event by id. Defaults to a random id when omitted from the DSL.

Link copied to clipboard
@SerialName(value = "trigger")
open override val trigger: EventTrigger

The condition that must occur for this event to run — matched by structural equality (data class/data object equality) against whatever trigger value fired, never by any kind of subscription or listener registry.