Class WaterLevelSnapshot
- Namespace
- EncDotNet.S100.Navigation
- Assembly
- EncDotNet.S100.Navigation.dll
The water level at one instant, from an IWaterLevelSource.
public sealed class WaterLevelSnapshot : IWaterLevelField
- Inheritance
-
WaterLevelSnapshot
- Implements
- Inherited Members
Remarks
The value is interpolated linearly between the bracketing steps (ValueAt(DateTime)). A point whose series don't cover the time isn't adjusted.
Constructors
WaterLevelSnapshot(IWaterLevelSource, DateTime)
Creates the field.
public WaterLevelSnapshot(IWaterLevelSource source, DateTime utc)
Parameters
sourceIWaterLevelSourceThe water-level source.
utcDateTimeThe time; a local time is converted, an unspecified one is taken as UTC.
Properties
Basis
What the field applies: the time or period, and the datasets.
public WaterLevelBasis Basis { get; }
Property Value
Footprint
The areas where the field can apply, in WGS-84, for the adjusted-area boundary. Empty when the source can't describe them.
public IReadOnlyList<CoverageArea> Footprint { get; }
Property Value
Time
The time the field is for (UTC).
public DateTime Time { get; }
Property Value
Methods
Resolve(GeoPosition, int?)
The water level at a point for a depth on depthDatum,
with the reason when none applies.
public WaterLevelAtPoint Resolve(GeoPosition position, int? depthDatum)
Parameters
positionGeoPositionThe point, in WGS-84.
depthDatumint?The charted depth's vertical datum as an S-100 code, or
nullwhen it isn't declared.
Returns
- WaterLevelAtPoint
The outcome.
Resolve(IReadOnlyList<IWaterLevelSeries>, DateTime, int?)
The water level at utc from series already located
at a point, most preferred first, by the rule every
IWaterLevelField and the passage check share.
public static WaterLevelAtPoint Resolve(IReadOnlyList<IWaterLevelSeries> series, DateTime utc, int? depthDatum)
Parameters
seriesIReadOnlyList<IWaterLevelSeries>The series at the point, most preferred first.
utcDateTimeThe time (UTC).
depthDatumint?The charted depth's datum, or
null.
Returns
- WaterLevelAtPoint
The outcome.
Sample(GeoPosition)
The water level to apply at a point, or null where none
applies. No depth datum is compared; use Resolve(GeoPosition, int?) to
compare one.
public AppliedWaterLevel? Sample(GeoPosition position)
Parameters
positionGeoPositionThe point, in WGS-84.
Returns
- AppliedWaterLevel?
The water level, or
null.