OnStateEvent

@OnMessage(functionKind = FunctionKind.STATE_EVENT, defaultFunctionName = "onStateEvent")
annotation class OnStateEvent(val value: String)

On State Event.

Local Context:

    @OnStateEvent
fun onStateEvent(changed: Changed, state: State) {
//...
}

Remote Context:

    @OnStateEvent
fun onStateEvent(changed: Changed, stateRecord: StateRecord) {
val state = stateRecord.toObject<StateData>()
//...
}

Author

ahoo wang

Properties

Link copied to clipboard
val value: Array<out String>

aggregate Names