Skip to main content

Interface: FlightPlanDataArray

Defined in: src/workingtitle-instruments-g3x-touch/html_ui/Shared/FlightPlan/FlightPlanDataArray.ts:9

A subscribable array of flight plan data items describing how to display details of a flight plan in a list format.

Extends

Properties

cumulativeDataFields

readonly cumulativeDataFields: readonly Subscribable<null | FlightPlanDataField<FlightPlanDataFieldType>>[]

Defined in: src/workingtitle-instruments-g3x-touch/html_ui/Shared/FlightPlan/FlightPlanDataArray.ts:17

The data fields representing cumulative total values over this array's entire flight plan.


fromLegIndex

readonly fromLegIndex: Subscribable<number>

Defined in: src/workingtitle-instruments-g3x-touch/html_ui/Shared/FlightPlan/FlightPlanDataArray.ts:11

The index of the data item associated with the FROM flight plan leg, or -1 if there is no such leg.


length

readonly length: number

Defined in: src/sdk/sub/SubscribableArray.ts:27

The length of this array.

Inherited from

SubscribableArray.length


toLegIndex

readonly toLegIndex: Subscribable<number>

Defined in: src/workingtitle-instruments-g3x-touch/html_ui/Shared/FlightPlan/FlightPlanDataArray.ts:14

The index of the data item associated with the TO flight plan leg, or -1 if there is no such leg.

Methods

get()

get(index): FlightPlanDataItem

Defined in: src/sdk/sub/SubscribableArray.ts:35

Retrieves an element from this array.

Parameters

ParameterTypeDescription
indexnumberThe index of the element.

Returns

FlightPlanDataItem

the element at the specified index.

Throws

Error if index is out of bounds.

Inherited from

SubscribableArray.get


getArray()

getArray(): readonly FlightPlanDataItem[]

Defined in: src/sdk/sub/SubscribableArray.ts:48

Gets a read-only version of this array.

Returns

readonly FlightPlanDataItem[]

a read-only version of this array.

Inherited from

SubscribableArray.getArray


sub()

sub(handler, initialNotify?, paused?): Subscription

Defined in: src/sdk/sub/SubscribableArray.ts:58

Subscribes to changes in this array's state.

Parameters

ParameterTypeDescription
handlerSubscribableArrayHandler<FlightPlanDataItem>A function which is called when this array's state changes.
initialNotify?booleanWhether to immediately invoke the callback function with this array's current state. Defaults to false. This argument is ignored if the subscription is initialized as paused.
paused?booleanWhether the new subscription should be initialized as paused. Defaults to false.

Returns

Subscription

The new subscription.

Inherited from

SubscribableArray.sub


tryGet()

tryGet(index): undefined | FlightPlanDataItem

Defined in: src/sdk/sub/SubscribableArray.ts:42

Attempts to retrieve an element from this array.

Parameters

ParameterTypeDescription
indexnumberThe index of the element.

Returns

undefined | FlightPlanDataItem

the element at the specified index, or undefined if index is out of bounds.

Inherited from

SubscribableArray.tryGet


unsub()

unsub(handler): void

Defined in: src/sdk/sub/SubscribableArray.ts:66

Unsubscribes a callback function from this array.

Parameters

ParameterTypeDescription
handlerSubscribableArrayHandler<FlightPlanDataItem>The function to unsubscribe.

Returns

void

Deprecated

This method has been deprecated in favor of using the Subscription object returned by .sub() to manage subscriptions.

Inherited from

SubscribableArray.unsub