Click or drag to resize

EagerLoad Constructor (EagerLoadType)

Creates an EagerLoad object. Only the specified flags will be set to eager load.

Namespace:  CoordinateSharp
Assembly:  CoordinateSharp (in CoordinateSharp.dll) Version: 2.12.1.1
Syntax
C#
public EagerLoad(
	EagerLoadType et
)

Parameters

et
Type: CoordinateSharpEagerLoadType
EagerLoadType
Examples
The following example sets CelestialInfo and Cartesian properties to eager load. Other conversions will be lazy loaded.
//Create an EagerLoading object with only CelestialInfo and Cartesian properties set to eager load.
EagerLoad el = new EagerLoad(EagerLoadType.Celestial | EagerLoadType.Cartesian);

//Create coordinate with defined eagerloading settings.
Coordinate coord = new Coordinate(25, 25, new DateTime(2018, 3, 2), el);

//Display UTC sunset time at the location.
Console.WriteLine(coord.CelestialInfo.SunSet); //3/2/2018 4:23:46 PM
Console.WriteLine(coord.Cartesian); //0.8213938 0.38302222 0.42261826

//Load UTM_MGRS when ready.
coord.LoadUTM_MGRS_Info();
Console.WriteLine(coord.UTM); //35R 298154mE 2766437mN
See Also