Package-level declarations

Types

Link copied to clipboard

Abstract class for components that are part of the pulverisation model in the strict setup.

Link copied to clipboard
abstract class Actuators<in AS : Any>(serializer: KSerializer<AS>) : AbstractPulverizedComponent

Represents the Actuators component in the pulverization model.

Link copied to clipboard
abstract class Behavior<State : Any, Comm : Any, in Sensors : Any, out Actuators : Any>(executionScheduler: ExecutionScheduler, stateSerializer: KSerializer<StateOps<State>> = serializer(), commSerializer: KSerializer<CommunicationPayload<Comm>> = serializer(), sensorsSerializer: KSerializer<Sensors>, actuatorsSerializer: KSerializer<Actuators>) : AbstractPulverizedComponent

Represents the Behavior component in the pulverization model. The behavior can manage the State of the component, the Communication with the other devices, the Sensors and the Actuators. The behavior is executed according to the ExecutionScheduler.

Link copied to clipboard
data class BehaviourOutput<out State : Any, out Comm : Any, out Actuators : Any>(val state: State?, val comm: Comm?, val actuators: Actuators?)

Models the output of a Behavior where state is the new state of the component, comm is the communication to be sent to the other devices and actuators is the prescriptive actions to be performed.

Link copied to clipboard
abstract class Communication<Comm : Any>(serializer: KSerializer<CommunicationPayload<Comm>>) : AbstractPulverizedComponent

Represents the Communication component in the pulverization model.

Link copied to clipboard
@Serializable
data class CommunicationPayload<Comm : Any>(val deviceId: Id, val payload: Comm)

Represents the payload of a communication.

Link copied to clipboard
@Serializable
object GetState : StateOps<Nothing>

Represents the operation of querying the state of a State component.

Link copied to clipboard
abstract class Sensors<out SS : Any>(executionScheduler: ExecutionScheduler, serializer: KSerializer<SS>) : AbstractPulverizedComponent

Represents the Sensors component in the pulverization model.

Link copied to clipboard
@Serializable
data class SetState<StateRepr : Any>(val content: StateRepr) : StateOps<StateRepr>

Represents the operation of setting the state of a State component with a new content.

Link copied to clipboard
abstract class State<StateRepr : Any>(serializer: KSerializer<StateOps<StateRepr>>) : AbstractPulverizedComponent

Represents the State component in the pulverization model.

Link copied to clipboard
@Serializable(with = StateOpsSerializer::class)
sealed interface StateOps<out StateRepr : Any>

Represents the operations that can be performed on a State component.