Directive

data class Directive<A : Any>(val inner: A, val name: String, val id: ActivityDirectiveId, val type: String, val start: DirectiveStart) : Activity<Directive<A>>

A wrapper of any type of activity directive containing common data.

Constructors

Link copied to clipboard
constructor(inner: A, name: String, id: ActivityDirectiveId, type: String, start: DirectiveStart)

Properties

Link copied to clipboard
val id: ActivityDirectiveId

The directive id.

Link copied to clipboard

The inner payload, typically either AnyDirective or a mission model activity type.

Link copied to clipboard
open override val interval: Interval

The interval this occupies on the timeline.

Link copied to clipboard

The name of this specific directive.

Link copied to clipboard

The start behavior for this directive.

Link copied to clipboard
open override val startTime: Duration

Time that the activity starts.

Link copied to clipboard
open override val type: String

String type name of the activity.

Functions

Link copied to clipboard
fun <R : Any> mapInner(f: (A) -> R): Directive<R>

Transform the inner payload with a function, returning a new directive object.

Link copied to clipboard
open override fun withNewInterval(i: Interval): Directive<A>

Creates a new object that is identical except that it exists on a different interval.