Class: FacilityUtils
Defined in: src/sdk/navigation/Facilities.ts:1367
Utility functions for working with facilities.
Constructors
Constructor
new FacilityUtils():
FacilityUtils
Returns
FacilityUtils
Methods
getLatLonFromRadialDistance()
static
getLatLonFromRadialDistance(reference
,radial
,distance
,out
):GeoPoint
Defined in: src/sdk/navigation/Facilities.ts:1412
Gets latitude/longitude coordinates corresponding to a radial and distance from a reference facility.
Parameters
Parameter | Type | Description |
---|---|---|
reference | Facility | The reference facility. |
radial | number | The magnetic radial, in degrees. |
distance | number | The distance, in nautical miles. |
out | GeoPoint | The GeoPoint object to which to write the result. |
Returns
The latitude/longitude coordinates corresponding to the specified radial and distance from the reference facility.
getLatLonFromRadialRadial()
static
getLatLonFromRadialRadial(reference1
,radial1
,reference2
,radial2
,out
):GeoPoint
Defined in: src/sdk/navigation/Facilities.ts:1430
Gets latitude/longitude coordinates corresponding to the intersection of two facility radials.
Parameters
Parameter | Type | Description |
---|---|---|
reference1 | Facility | The first reference facility. |
radial1 | number | The first magnetic radial, in degrees. |
reference2 | Facility | The second reference facility. |
radial2 | number | The second magnetic radial, in degrees. |
out | GeoPoint | The GeoPoint object to which to write the result. |
Returns
The latitude/longitude coordinates corresponding to the intersection of the two specified radials. If
the specified radials do not intersect at a unique point, NaN
is written to both lat
and lon
.
getMagVar()
static
getMagVar(facility
):number
Defined in: src/sdk/navigation/Facilities.ts:1395
Gets the magnetic variation at a facility, in degrees. If the facility is a VOR, the magnetic variation defined by the VOR is returned. For all other facilities, the modeled magnetic variation at the location of the facility is returned.
Parameters
Parameter | Type | Description |
---|---|---|
facility | Facility | A facility. |
Returns
number
The magnetic variation at the specified facility, in degrees.
isFacilityType()
static
isFacilityType<T
>(facility
,type
):facility is FacilityTypeMap[T]
Defined in: src/sdk/navigation/Facilities.ts:1378
Checks whether a facility is of a given type.
Type Parameters
Type Parameter |
---|
T extends FacilityType |
Parameters
Parameter | Type | Description |
---|---|---|
facility | Facility | The facility to check. |
type | T | The facility type to check against. |
Returns
facility is FacilityTypeMap[T]
Whether the facility is of the specified type.