Class: WT21PilotWaypointUtils
Utilities for WT21 pilot defined waypoints
Constructors
constructor
• new WT21PilotWaypointUtils(): WT21PilotWaypointUtils
Returns
Methods
createAlongTrackOffset
▸ createAlongTrackOffset(facLoader
, plan
, globalLegIndex
, lnavActiveLegIndex
, lnavDistanceAlongActiveLeg
, distance
): Promise
<[point: GeoPoint, insertAfter: boolean] | AlongTrackOffsetError
>
Creates an along-track offset position with input data
Parameters
Name | Type | Description |
---|---|---|
facLoader | FacilityLoader | the facility loader |
plan | FlightPlan | the flight plan the ATO is being created from |
globalLegIndex | number | the global leg index in the plan the ATO is being created from (WT21: LSK position) |
lnavActiveLegIndex | number | the active lnav leg index (not nominal) |
lnavDistanceAlongActiveLeg | number | the distance flown along the active lnav leg |
distance | number | the distance input |
Returns
Promise
<[point: GeoPoint, insertAfter: boolean] | AlongTrackOffsetError
>
a GeoPoint
Defined in
workingtitle-instruments-wt21/instruments/html_ui/Pages/VCockpit/Instruments/WT21/FMC/Navigation/WT21PilotWaypointUtils.ts:425
createFromScratchpadEntry
▸ createFromScratchpadEntry(fms
, selectWptFromIdent
, scratchpadContents
, targetGlobalLegIndex?
): Promise
<null
| [fac: UserFacility, insertAfter: boolean]>
Converts a scratchpad entry made on a provided CDU page to a UserFacility if applicable
Parameters
Name | Type | Description |
---|---|---|
fms | WT21Fms | the WT21Fms instance |
selectWptFromIdent | (ident : string , refPos : GeoPoint ) => Promise <null | Facility > | the function called to select a facility |
scratchpadContents | string | the scratchpad contents |
targetGlobalLegIndex? | number | the target global leg index, if applicable |
Returns
Promise
<null
| [fac: UserFacility, insertAfter: boolean]>
a user facility, or null if none is parsed
Defined in
workingtitle-instruments-wt21/instruments/html_ui/Pages/VCockpit/Instruments/WT21/FMC/Navigation/WT21PilotWaypointUtils.ts:146
createPlaceBearingDistance
▸ createPlaceBearingDistance(facility
, bearing
, bearingTrue
, distance
): GeoPoint
Creates a PB/D position with input data
Parameters
Name | Type | Description |
---|---|---|
facility | Facility | the facility representing the origin |
bearing | number | the bearing to use |
bearingTrue | boolean | whether the bearing is already provided in TRUE form |
distance | number | the distance to use |
Returns
GeoPoint
a GeoPoint
Defined in
workingtitle-instruments-wt21/instruments/html_ui/Pages/VCockpit/Instruments/WT21/FMC/Navigation/WT21PilotWaypointUtils.ts:296
createPlaceBearingPlaceBearing
▸ createPlaceBearingPlaceBearing(facilityA
, bearingA
, facilityB
, bearingB
): null
| GeoPoint
Creates a PB/PB position with input data
Parameters
Name | Type | Description |
---|---|---|
facilityA | Facility | the facility representing the first origin |
bearingA | number | the bearing to use from the first origin |
facilityB | Facility | the facility representing the second origin |
bearingB | number | the distance to use from the second origin |
Returns
null
| GeoPoint
a GeoPoint
Defined in
workingtitle-instruments-wt21/instruments/html_ui/Pages/VCockpit/Instruments/WT21/FMC/Navigation/WT21PilotWaypointUtils.ts:359
isLimitReached
▸ isLimitReached(facilities
): boolean
Returns whether the limit number of pilot defined waypoints is reached
Parameters
Name | Type | Description |
---|---|---|
facilities | UserFacility [] | the existing user facilities |
Returns
boolean
a boolean
Defined in
workingtitle-instruments-wt21/instruments/html_ui/Pages/VCockpit/Instruments/WT21/FMC/Navigation/WT21PilotWaypointUtils.ts:110
nextAutoGeneratedName
▸ nextAutoGeneratedName(facilities
, ident
): string
Returns the next available auto-generated name, given existing user facilities and an ident
Parameters
Name | Type | Description |
---|---|---|
facilities | UserFacility [] | the existing user facilities |
ident | string | the ident of the facility |
Returns
string
a string to be used as an ident for a user facility
Defined in
workingtitle-instruments-wt21/instruments/html_ui/Pages/VCockpit/Instruments/WT21/FMC/Navigation/WT21PilotWaypointUtils.ts:122
parseAlongTrackOffset
▸ parseAlongTrackOffset(str
): null
| AlongTrackOffsetInput
Parses a string according to the along-track offset format
Parameters
Name | Type | Description |
---|---|---|
str | string | the string to parse |
Returns
null
| AlongTrackOffsetInput
a AlongTrackOffsetInput object if a valid ATO definition and null
otherwise
Defined in
workingtitle-instruments-wt21/instruments/html_ui/Pages/VCockpit/Instruments/WT21/FMC/Navigation/WT21PilotWaypointUtils.ts:399
parsePlaceBearingDistance
▸ parsePlaceBearingDistance(str
): null
| PlaceBearingDistanceInput
Parses a string according to the PB/D format
Parameters
Name | Type | Description |
---|---|---|
str | string | the string to parse |
Returns
null
| PlaceBearingDistanceInput
a PlaceBearingDistanceInput object if a valid PBD definition and null
otherwise
Defined in
workingtitle-instruments-wt21/instruments/html_ui/Pages/VCockpit/Instruments/WT21/FMC/Navigation/WT21PilotWaypointUtils.ts:265
parsePlaceBearingPlaceBearing
▸ parsePlaceBearingPlaceBearing(str
): null
| PlaceBearingPlaceBearingInput
Parses a string according to the PB/PB format
Parameters
Name | Type | Description |
---|---|---|
str | string | the string to parse |
Returns
null
| PlaceBearingPlaceBearingInput
a PlaceBearingPlaceBearingInput object if a valid PBPB definition and null
otherwise
Defined in
workingtitle-instruments-wt21/instruments/html_ui/Pages/VCockpit/Instruments/WT21/FMC/Navigation/WT21PilotWaypointUtils.ts:326