Class: FlightPlanSegmentData
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanSegmentListData.ts:62
Represents a flight plan segment data object. It stores lots of useful info about the segment in handy dandy subscribables.
Implements
Constructors
Constructor
new FlightPlanSegmentData(
segment,planIndex,store,plan):FlightPlanSegmentData
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanSegmentListData.ts:92
Creates a new leg list data object.
Parameters
| Parameter | Type | Description |
|---|---|---|
segment | FlightPlanSegment | The containing segment. |
planIndex | number | The index of the flight plan that this leg belongs to. |
store | FlightPlanStore | The flight plan store. |
plan | FlightPlan | The flight plan that this leg exists in. |
Returns
FlightPlanSegmentData
Properties
airway
readonlyairway:Subscribable<undefined|string>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanSegmentListData.ts:68
The airway name of the segment, or undefined if the segment is not an airway.
distance
readonlydistance:NumberUnitSubject<Distance,SimpleUnit<Distance>>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanSegmentListData.ts:78
The total distance of all legs in the segment.
estimatedTimeEnroute
readonlyestimatedTimeEnroute:NumberUnitSubject<Duration,SimpleUnit<Duration>>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanSegmentListData.ts:81
The total estimated time enroute of all legs in the segment.
isAirway
readonlyisAirway:Subscribable<boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanSegmentListData.ts:71
Whether the segment is an airway.
plan
readonlyplan:FlightPlan
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanSegmentListData.ts:97
The flight plan that this leg exists in.
planIndex
readonlyplanIndex:number
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanSegmentListData.ts:95
The index of the flight plan that this leg belongs to.
segment
readonlysegment:FlightPlanSegment
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanSegmentListData.ts:94
A reference to the segment in the flight plan.
segmentIndex
readonlysegmentIndex:Subscribable<number>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanSegmentListData.ts:75
The index of the segment in the flight plan.
type
readonlytype:"segment"='segment'
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanSegmentListData.ts:64
The type of flight plan list item.
Implementation of
Methods
destroy()
destroy():
void
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanSegmentListData.ts:122
Call when this leg is rmoved from the plan.
Returns
void
onAirwayChanged()
onAirwayChanged(
airway):void
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanSegmentListData.ts:117
Handles the airway changing.
Parameters
| Parameter | Type | Description |
|---|---|---|
airway | undefined | string | The new airway. |
Returns
void
updateSegmentIndex()
updateSegmentIndex(
segmentIndex):void
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanSegmentListData.ts:109
Sets the new segment index.
Parameters
| Parameter | Type | Description |
|---|---|---|
segmentIndex | number | The new segment index. |
Returns
void