Class: FlightPlanLegData
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:227
Represents a flight plan leg data object. It stores lots of useful info about the leg in handy dandy subscribables.
Implements
Constructors
Constructor
new FlightPlanLegData(
leg,segment,segmentData,planIndex,isAdvancedVnav,store,plan,globalLegIndex,isDirectToRandom):FlightPlanLegData
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:475
Creates a new leg data object.
Parameters
| Parameter | Type | Default value | Description |
|---|---|---|---|
leg | LegDefinition | undefined | The leg definition. |
segment | FlightPlanSegment | undefined | The containing segment. |
segmentData | undefined | FlightPlanSegmentData | undefined | The containing segment data. Not needed for random direct to. |
planIndex | number | undefined | The index of the flight plan that this leg belongs to. |
isAdvancedVnav | boolean | undefined | Whether this is for advanced vnav. |
store | FlightPlanStore | undefined | The flight plan store. |
plan | FlightPlan | undefined | The flight plan that this leg exists in. |
globalLegIndex | number | undefined | The global leg index. |
isDirectToRandom | boolean | false | Whether this leg is for a direct to random. |
Returns
FlightPlanLegData
Properties
altDesc
readonlyaltDesc:Subject<AltitudeRestrictionType>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:292
The altitude restriction type to use for the altitude constraint.
altDescDisplay
readonlyaltDescDisplay:MappedSubject<[boolean,AltitudeRestrictionType,boolean],AltitudeRestrictionType>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:336
The alt desc, but for display in a list.
altitude1
readonlyaltitude1:NumberUnitSubject<Distance,SimpleUnit<Distance>>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:295
The altitude 1 to use for the altitude constraint.
altitude1Display
readonlyaltitude1Display:NumberUnitSubject<Distance,SimpleUnit<Distance>>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:322
The altitude 1 to use for the altitude constraint, but for display in a list.
altitude2
readonlyaltitude2:NumberUnitSubject<Distance,SimpleUnit<Distance>>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:298
The altitude 2 to use for the altitude constraint.
altitude2Display
readonlyaltitude2Display:NumberUnitSubject<Distance,SimpleUnit<Distance>>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:325
The altitude 2 to use for the altitude constraint, but for display in a list.
courseRounded
readonlycourseRounded:number
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:441
The leg course, rounded, and with 0 as 360.
displayAltitude1AsFlightLevel
readonlydisplayAltitude1AsFlightLevel:Subject<boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:301
Whether the altitude 1 should be displayed as a flight level.
displayAltitude1AsFlightLevelDisplay
readonlydisplayAltitude1AsFlightLevelDisplay:MappedSubject<[boolean,boolean],boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:365
Whether to display altitude 1 as a flight level, but for display in a list.
displayAltitude2AsFlightLevel
readonlydisplayAltitude2AsFlightLevel:Subject<boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:304
Whether the altitude 2 should be displayed as a flight level.
displayAltitude2AsFlightLevelDisplay
readonlydisplayAltitude2AsFlightLevelDisplay:MappedSubject<[boolean,boolean],boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:374
Whether to display altitude 2 as a flight level, but for display in a list.
distance
readonlydistance:NumberUnitSubject<Distance,SimpleUnit<Distance>>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:444
The leg's total distance, not cut short by ingress/egress turn radii. Changes when active leg.
distanceCumulative
readonlydistanceCumulative:NumberUnitSubject<Distance,SimpleUnit<Distance>>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:447
The cumulative distance up to the end of this leg.
estimatedTimeEnroute
readonlyestimatedTimeEnroute:NumberUnitSubject<Duration,SimpleUnit<Duration>>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:453
Estimated time Enroute of the leg, in seconds duration. How long it will take to fly the leg.
estimatedTimeEnrouteCumulative
readonlyestimatedTimeEnrouteCumulative:NumberUnitSubject<Duration,SimpleUnit<Duration>>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:456
Cumulative ETE. How long it would take from the current position to the end of this leg.
estimatedTimeOfArrival
readonlyestimatedTimeOfArrival:Subject<number>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:459
Estimated Time of Arrival of the leg, in UTC milliseconds from midnight.
fpa
readonlyfpa:Subject<number>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:414
This leg's flight path angle, in degrees, or NaN if there is no defined flight path angle. Positive values
indicate a descending path.
fuelRemaining
readonlyfuelRemaining:NumberUnitSubject<Weight,SimpleUnit<Weight>>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:450
The estimated fuel remaining at the end of the leg.
globalLegIndex
readonlyglobalLegIndex:Subject<number>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:241
The global index of this leg.
initialDtk
readonlyinitialDtk:BasicNavAngleSubject
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:438
The initial DTK of the leg. Magnetic.
isActiveLeg
readonlyisActiveLeg:Subject<boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:275
Whether this is the active leg in the flight plan.
isAltitudeCyan
readonlyisAltitudeCyan:MappedSubject<[boolean,NumberUnitInterface<Distance,SimpleUnit<Distance>>,boolean,boolean],boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:328
Whether this leg's altitude should be display in cyan or not.
isAltitudeDesignated
readonlyisAltitudeDesignated:Subject<boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:307
Whether the altitude constraint is designated or not.
isAltitudeEditable
readonlyisAltitudeEditable:Subject<boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:316
Whether this leg's altitude constraint is editable.
isAltitudeEdited
readonlyisAltitudeEdited:Subject<boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:310
Whether this leg's altitude constraint is different from the published constraint.
isAltitudeEditedDisplay
readonlyisAltitudeEditedDisplay:MappedSubject<[boolean,boolean],boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:347
Whether the altitude is edited, but for display in a list.
isAltitudeInvalid
readonlyisAltitudeInvalid:Subject<boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:313
Whether this leg's altitude constraint is invalid or not.
isAltitudeInvalidDisplay
readonlyisAltitudeInvalidDisplay:MappedSubject<[boolean,boolean],boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:356
Whether the altitude is invalid, but for display in a list.
isAltitudeVisible
readonlyisAltitudeVisible:Subject<boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:319
Whether this leg's altitude constraint is visible.
isApproachRunwayLeg
readonlyisApproachRunwayLeg:boolean
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:266
Whether this leg is a runway in the approach segment.
isBehindActiveLeg
readonlyisBehindActiveLeg:Subject<boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:278
Whether this leg is before the active leg.
isDirectToRandom
readonlyisDirectToRandom:boolean=false
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:484
Whether this leg is for a direct to random.
isDtoLeg
readonlyisDtoLeg:MappedSubscribable<boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:281
Whether this is a direct to leg.
isEditableDisplay
readonlyisEditableDisplay:MappedSubject<[boolean,boolean],boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:383
Whether the altitude is editable, but for display in a list.
isFirstLegInPlan
readonlyisFirstLegInPlan:Subject<boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:272
Whether this is currently the first leg in the plan.
isFirstLegInSegment
readonlyisFirstLegInSegment:MappedSubscribable<boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:247
Whether this leg is the first leg in its segment.
isFpaEdited
readonlyisFpaEdited:Subject<boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:417
Whether this leg's fpa has been set by the user.
isFpaSpeedEditable
readonlyisFpaSpeedEditable:Subject<boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:420
Whether this leg's fpa and speed constraint are editable.
isHeadingLeg
readonlyisHeadingLeg:boolean
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:287
isHoldLeg
readonlyisHoldLeg:boolean
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:285
isInAirwaySegment
readonlyisInAirwaySegment:Subscribable<boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:269
Whether this leg is in an airway segment.
isInApproachSegment
readonlyisInApproachSegment:boolean
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:257
Whether this leg is in the approach segment.
isInDepartureSegment
readonlyisInDepartureSegment:boolean
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:254
Whether this leg is in the departure segment.
isInMissedApproach
readonlyisInMissedApproach:boolean
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:260
Whether this leg is in the missed approach.
isLastLegInSegment
readonlyisLastLegInSegment:Subscribable<boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:251
Whether this leg is the first leg in its segment.
isRunway
readonlyisRunway:boolean
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:263
Whether this leg is a runway.
isSpeedEdited
readonlyisSpeedEdited:Subject<boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:403
Whether this leg's speed constraint is different from the published speed.
isSpeedInvalid
readonlyisSpeedInvalid:Subject<boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:406
Whether this leg's speed constraint is invalid or not.
isVisibleLegType
readonlyisVisibleLegType:boolean
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:232
Whether this leg's flags and leg type allow for the leg to be visible.
leg
readonlyleg:LegDefinition
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:476
The leg definition.
plan
readonlyplan:FlightPlan
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:482
The flight plan that this leg exists in.
planIndex
readonlyplanIndex:number
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:479
The index of the flight plan that this leg belongs to.
segment
readonlysegment:FlightPlanSegment
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:477
The containing segment.
segmentData
readonlysegmentData:undefined|FlightPlanSegmentData
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:478
The containing segment data. Not needed for random direct to.
segmentLegIndex
readonlysegmentLegIndex:Subject<number>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:244
The index of this leg in its segment.
showClimbFpa
readonlyshowClimbFpa:MappedSubject<[VerticalFlightPhase,boolean,boolean],boolean>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:428
Whether to show CLIMB for the fpa.
speed
readonlyspeed:Subject<number>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:394
This leg's speed constraint speed.
speedDesc
readonlyspeedDesc:Subject<SpeedRestrictionType>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:400
This leg's speed constraint type.
speedUnit
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:397
This leg's speed constraint units.
type
readonlytype:"leg"='leg'
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:229
The type of flight plan list item.
Implementation of
vnavPhase
readonlyvnavPhase:Subject<VerticalFlightPhase>
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:425
The vertical flight phase.
Methods
destroy()
destroy():
void
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:637
Call when this leg is removed from the plan.
Returns
void
handleLegChanged()
handleLegChanged(
leg):void
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:539
Handles the leg changed event. Effectively when the vertical data object on the leg was modified.
Parameters
| Parameter | Type | Description |
|---|---|---|
leg | LegDefinition | The leg definition. |
Returns
void
updateLegListDataAltitudeStuffFromVerticalData()
updateLegListDataAltitudeStuffFromVerticalData():
void
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:566
Updates a leg list data item's altitude info from the leg's vertical data object.
Returns
void
updateLegPosition()
updateLegPosition(
globalLegIndex):void
Defined in: src/workingtitle-instruments-g3000/html_ui/Shared/FlightPlan/FlightPlanLegListData.ts:501
Update leg based on it's global leg index. We avoid storing indexes to avoid stale indexes.
Parameters
| Parameter | Type | Description |
|---|---|---|
globalLegIndex | number | The global leg index of the leg. |
Returns
void