ActionsCommands

interface ActionsCommands

Known direct subclasses
Actions

API for the Actions trait.


Summary

Public functions

suspend Unit

Disable an action.

suspend Unit
disableActionWithDuration(
    actionId: UShort,
    duration: UInt,
    optionalArgs: ActionsTrait.DisableActionWithDurationCommand.OptionalArgs.() -> Unit
)

Disable an action for a specified amount of time, then enable it.

suspend Unit

Enable an action.

suspend Unit
enableActionWithDuration(
    actionId: UShort,
    duration: UInt,
    optionalArgs: ActionsTrait.EnableActionWithDurationCommand.OptionalArgs.() -> Unit
)

Enable an action for a specified amount of time, then disable it.

suspend Unit

Trigger an action (state change) on endpoints in an asynchronous manner.

suspend Unit
instantActionWithTransition(
    actionId: UShort,
    transitionTime: UShort,
    optionalArgs: ActionsTrait.InstantActionWithTransitionCommand.OptionalArgs.() -> Unit
)

Trigger an action (state change) on endpoints, specifying how long the state change should take.

suspend Unit

Pause an ongoing action.

suspend Unit
pauseActionWithDuration(
    actionId: UShort,
    duration: UInt,
    optionalArgs: ActionsTrait.PauseActionWithDurationCommand.OptionalArgs.() -> Unit
)

Pause an ongoing action for a specified amount of time, after which it resumes.

suspend Unit

Resume a paused action.

suspend Unit

Start an action.

suspend Unit
startActionWithDuration(
    actionId: UShort,
    duration: UInt,
    optionalArgs: ActionsTrait.StartActionWithDurationCommand.OptionalArgs.() -> Unit
)

Start an action, allow it to run for a specified amount of time, after which it stops.

suspend Unit

Stop the ongoing action.

Public functions

disableAction

suspend fun disableAction(actionId: UShort, optionalArgs: ActionsTrait.DisableActionCommand.OptionalArgs.() -> Unit = {}): Unit

Disable an action.

Parameters
optionalArgs: ActionsTrait.DisableActionCommand.OptionalArgs.() -> Unit = {}

Receiver for the optional arguments of this command

disableActionWithDuration

suspend fun disableActionWithDuration(
    actionId: UShort,
    duration: UInt,
    optionalArgs: ActionsTrait.DisableActionWithDurationCommand.OptionalArgs.() -> Unit = {}
): Unit

Disable an action for a specified amount of time, then enable it.

Parameters
duration: UInt

The requested duration in seconds.

optionalArgs: ActionsTrait.DisableActionWithDurationCommand.OptionalArgs.() -> Unit = {}

Receiver for the optional arguments of this command

enableAction

suspend fun enableAction(actionId: UShort, optionalArgs: ActionsTrait.EnableActionCommand.OptionalArgs.() -> Unit = {}): Unit

Enable an action.

Parameters
optionalArgs: ActionsTrait.EnableActionCommand.OptionalArgs.() -> Unit = {}

Receiver for the optional arguments of this command

enableActionWithDuration

suspend fun enableActionWithDuration(
    actionId: UShort,
    duration: UInt,
    optionalArgs: ActionsTrait.EnableActionWithDurationCommand.OptionalArgs.() -> Unit = {}
): Unit

Enable an action for a specified amount of time, then disable it.

Parameters
duration: UInt

The requested duration in seconds.

optionalArgs: ActionsTrait.EnableActionWithDurationCommand.OptionalArgs.() -> Unit = {}

Receiver for the optional arguments of this command

instantAction

suspend fun instantAction(actionId: UShort, optionalArgs: ActionsTrait.InstantActionCommand.OptionalArgs.() -> Unit = {}): Unit

Trigger an action (state change) on endpoints in an asynchronous manner.

Parameters
optionalArgs: ActionsTrait.InstantActionCommand.OptionalArgs.() -> Unit = {}

Receiver for the optional arguments of this command

instantActionWithTransition

suspend fun instantActionWithTransition(
    actionId: UShort,
    transitionTime: UShort,
    optionalArgs: ActionsTrait.InstantActionWithTransitionCommand.OptionalArgs.() -> Unit = {}
): Unit

Trigger an action (state change) on endpoints, specifying how long the state change should take.

Parameters
transitionTime: UShort

The transition time (in 0.1 seconds).

optionalArgs: ActionsTrait.InstantActionWithTransitionCommand.OptionalArgs.() -> Unit = {}

Receiver for the optional arguments of this command

pauseAction

suspend fun pauseAction(actionId: UShort, optionalArgs: ActionsTrait.PauseActionCommand.OptionalArgs.() -> Unit = {}): Unit

Pause an ongoing action.

Parameters
optionalArgs: ActionsTrait.PauseActionCommand.OptionalArgs.() -> Unit = {}

Receiver for the optional arguments of this command

pauseActionWithDuration

suspend fun pauseActionWithDuration(
    actionId: UShort,
    duration: UInt,
    optionalArgs: ActionsTrait.PauseActionWithDurationCommand.OptionalArgs.() -> Unit = {}
): Unit

Pause an ongoing action for a specified amount of time, after which it resumes.

Parameters
duration: UInt

The requested duration in seconds.

optionalArgs: ActionsTrait.PauseActionWithDurationCommand.OptionalArgs.() -> Unit = {}

Receiver for the optional arguments of this command

resumeAction

suspend fun resumeAction(actionId: UShort, optionalArgs: ActionsTrait.ResumeActionCommand.OptionalArgs.() -> Unit = {}): Unit

Resume a paused action.

Parameters
optionalArgs: ActionsTrait.ResumeActionCommand.OptionalArgs.() -> Unit = {}

Receiver for the optional arguments of this command

startAction

suspend fun startAction(actionId: UShort, optionalArgs: ActionsTrait.StartActionCommand.OptionalArgs.() -> Unit = {}): Unit

Start an action.

Parameters
optionalArgs: ActionsTrait.StartActionCommand.OptionalArgs.() -> Unit = {}

Receiver for the optional arguments of this command

startActionWithDuration

suspend fun startActionWithDuration(
    actionId: UShort,
    duration: UInt,
    optionalArgs: ActionsTrait.StartActionWithDurationCommand.OptionalArgs.() -> Unit = {}
): Unit

Start an action, allow it to run for a specified amount of time, after which it stops.

Parameters
duration: UInt

The requested duration in seconds.

optionalArgs: ActionsTrait.StartActionWithDurationCommand.OptionalArgs.() -> Unit = {}

Receiver for the optional arguments of this command

stopAction

suspend fun stopAction(actionId: UShort, optionalArgs: ActionsTrait.StopActionCommand.OptionalArgs.() -> Unit = {}): Unit

Stop the ongoing action.

Parameters
optionalArgs: ActionsTrait.StopActionCommand.OptionalArgs.() -> Unit = {}

Receiver for the optional arguments of this command