Skip to main content

Class: CourseToDmeLegCalculator

Calculates flight path vectors for course to DME legs.

Hierarchy

Constructors

constructor

new CourseToDmeLegCalculator(facilityCache): CourseToDmeLegCalculator

Constructor.

Parameters

NameTypeDescription
facilityCacheMap<string, Facility>This calculator's cache of facilities.

Returns

CourseToDmeLegCalculator

Overrides

CircleInterceptLegCalculator.constructor

Defined in

src/sdk/flightplan/FlightPathLegCalculator.ts:973

Properties

facilityCache

Protected Readonly facilityCache: Map<string, Facility>

This calculator's cache of facilities.

Inherited from

CircleInterceptLegCalculator.facilityCache

Defined in

src/sdk/flightplan/FlightPathLegCalculator.ts:43


includeInitialTurn

Protected Readonly includeInitialTurn: boolean

Whether this calculator should calculate an initial turn toward the intercept course.

Inherited from

CircleInterceptLegCalculator.includeInitialTurn

Defined in

src/sdk/flightplan/FlightPathLegCalculator.ts:609


skipWhenActive

Protected Readonly skipWhenActive: boolean = false

Whether this calculator will skip calculations for active legs when the leg has already been calculated. False by default.

Inherited from

CircleInterceptLegCalculator.skipWhenActive

Defined in

src/sdk/flightplan/FlightPathLegCalculator.ts:43

Methods

calculate

calculate(legs, calculateIndex, activeLegIndex, state, resolveIngressToEgress?): LegCalculations

Calculates flight path vectors for a flight plan leg and adds the calculations to the leg.

Parameters

NameTypeDefault valueDescription
legsLegDefinition[]undefinedA sequence of flight plan legs.
calculateIndexnumberundefinedThe index of the leg to calculate.
activeLegIndexnumberundefinedThe index of the active leg.
stateFlightPathStateundefinedThe current flight path state.
resolveIngressToEgressbooleantrue-

Returns

LegCalculations

The flight plan leg calculations.

Inherited from

CircleInterceptLegCalculator.calculate

Defined in

src/sdk/flightplan/FlightPathLegCalculator.ts:109


calculateMagVar

calculateMagVar(legs, calculateIndex): void

Calculates the magnetic variation for a flight plan leg.

Parameters

NameTypeDescription
legsLegDefinition[]A sequence of flight plan legs.
calculateIndexnumberThe index of the leg to calculate.

Returns

void

The number of vectors added to the sequence.

Overrides

CircleInterceptLegCalculator.calculateMagVar

Defined in

src/sdk/flightplan/FlightPathLegCalculator.ts:978


calculateVectors

calculateVectors(legs, calculateIndex, activeLegIndex, state): void

Calculates flight path vectors for a flight plan leg.

Parameters

NameTypeDescription
legsLegDefinition[]A sequence of flight plan legs.
calculateIndexnumberThe index of the leg to calculate.
activeLegIndexnumberThe index of the active leg.
stateFlightPathStateThe current flight path state.

Returns

void

The number of vectors added to the sequence.

Inherited from

CircleInterceptLegCalculator.calculateVectors

Defined in

src/sdk/flightplan/FlightPathLegCalculator.ts:614


getInterceptCourse

getInterceptCourse(legs, index): undefined | number

Gets the true intercept course bearing defined by a flight plan leg.

Parameters

NameTypeDescription
legsLegDefinition[]A sequence of leg definitions.
indexnumberThe index in the sequence of the leg from which to get the course.

Returns

undefined | number

The true intercept course bearing defined by the flight plan leg, or undefined if it could not be determined.

Overrides

CircleInterceptLegCalculator.getInterceptCourse

Defined in

src/sdk/flightplan/FlightPathLegCalculator.ts:991


getInterceptPathInfo

getInterceptPathInfo(legs, index, state, out): CircleInterceptPathInfo

Gets the geo circle path to intercept defined by a flight plan leg.

Parameters

NameTypeDescription
legsLegDefinition[]A sequence of leg definitions.
indexnumberThe index in the sequence of the leg from which to get the course.
stateFlightPathStateThe current flight path state.
outCircleInterceptPathInfoThe path info object to which to write the result.

Returns

CircleInterceptPathInfo

Information on the geo circle path to intercept defined by the flight plan leg.

Overrides

CircleInterceptLegCalculator.getInterceptPathInfo

Defined in

src/sdk/flightplan/FlightPathLegCalculator.ts:998


getLegMagVar

getLegMagVar(leg, point): number

Gets the magnetic variation, in degrees, to use when calculating a flight plan leg's course. If the leg defines an origin or fix VOR facility, then the magnetic variation defined at the VOR is used. Otherwise the computed magnetic variation for the specified point is used.

Parameters

NameTypeDescription
legFlightPlanLegA flight plan leg.
pointLatLonInterfaceThe location from which to get magnetic variation, if an origin VOR is not found.

Returns

number

The magnetic variation, in degrees, to use when calculating the specified flight plan leg's course.

Inherited from

CircleInterceptLegCalculator.getLegMagVar

Defined in

src/sdk/flightplan/FlightPathLegCalculator.ts:81


getLegTrueCourse

getLegTrueCourse(leg, point): number

Gets the true course, in degrees, for a flight plan leg. If the leg defines an origin or fix VOR facility, then the magnetic variation defined at the VOR is used to adjust magnetic course. Otherwise the computed magnetic variation for the specified point is used.

Parameters

NameTypeDescription
legFlightPlanLegA flight plan leg.
pointLatLonInterfaceThe location from which to get magnetic variation, if an origin VOR is not found.

Returns

number

The true course, in degrees, for the flight plan leg.

Inherited from

CircleInterceptLegCalculator.getLegTrueCourse

Defined in

src/sdk/flightplan/FlightPathLegCalculator.ts:100


getPositionFromIcao

getPositionFromIcao(icao, out): undefined | GeoPoint

Gets a geographical position from an ICAO string.

Parameters

NameTypeDescription
icaostringAn ICAO string.
outGeoPointA GeoPoint object to which to write the result.

Returns

undefined | GeoPoint

The geographical position corresponding to the ICAO string, or undefined if one could not be obtained.

Inherited from

CircleInterceptLegCalculator.getPositionFromIcao

Defined in

src/sdk/flightplan/FlightPathLegCalculator.ts:52


getTerminatorPosition

getTerminatorPosition(leg, icao, out): undefined | GeoPoint

Gets the geographic position for a flight plan leg terminator.

Parameters

NameTypeDescription
legFlightPlanLegA flight plan leg.
icaostringThe ICAO string of the leg's terminator fix.
outGeoPointA GeoPoint object to which to write the result.

Returns

undefined | GeoPoint

The position of the leg terminator, or undefined if it could not be determined.

Inherited from

CircleInterceptLegCalculator.getTerminatorPosition

Defined in

src/sdk/flightplan/FlightPathLegCalculator.ts:64


resolveIngressToEgress

resolveIngressToEgress(legCalc): void

Calculates the ingress to egress vectors for a flight plan leg and adds them to a leg calculation.

Parameters

NameTypeDescription
legCalcLegCalculationsThe calculations for a flight plan leg.

Returns

void

Inherited from

CircleInterceptLegCalculator.resolveIngressToEgress

Defined in

src/sdk/flightplan/FlightPathLegCalculator.ts:207


shouldSkipWhenActive

shouldSkipWhenActive(legs, calculateIndex, activeLegIndex, state): boolean

Checks whether vector calculations should be skipped when the leg to calculate is the active leg.

Parameters

NameTypeDescription
legsLegDefinition[]A sequence of flight plan legs.
calculateIndexnumberThe index of the leg to calculate.
activeLegIndexnumberThe index of the active leg.
stateFlightPathStateThe current flight path state.

Returns

boolean

Whether to skip vector calculations.

Inherited from

CircleInterceptLegCalculator.shouldSkipWhenActive

Defined in

src/sdk/flightplan/FlightPathLegCalculator.ts:178