Class WeatherParameterDefinition
One row of the canonical weather parameter table (design note weather-sources.md ยง3.5): a canonical id, its stored unit, and the GRIB2 codes and CF standard names readers map to it. The rows are listed in All.
public sealed class WeatherParameterDefinition
- Inheritance
-
WeatherParameterDefinition
- Inherited Members
Properties
CfStandardNames
The CF standard names for this parameter (CF standard name table), in order of preference: when a file holds more than one, a reader keeps the first.
public IReadOnlyList<string> CfStandardNames { get; }
Property Value
GribCodes
The GRIB2 (discipline, category, number) codes for this parameter (WMO code table 4.2), in order of preference: when a file holds more than one, a reader keeps the first.
public IReadOnlyList<GribParameterCode> GribCodes { get; }
Property Value
Group
The id of the parameter group this parameter is drawn with, for
example "wind" for the U and V components, speed and
direction. A WeatherCoverageSource serves one group.
public string Group { get; }
Property Value
Id
The canonical id, for example "wind.u" or "wave.hs".
public string Id { get; }
Property Value
Level
The level the canonical id refers to (10 m above ground for the wind components, speed and direction; mean sea level for pressure), or null when the id applies at whatever level the source gives. A reader maps a variable to this id only at this level; the same variable at another level is an unknown parameter.
public WeatherLevel? Level { get; }
Property Value
Name
A short display name, for example "Significant wave height".
public string Name { get; }
Property Value
Unit
The unit values are stored in. Readers convert to it.
public WeatherUnit Unit { get; }
Property Value
Methods
ToAngle(float)
Reads a stored value as an Angle clockwise from true north. Only for parameters in DegreesTrue.
public Angle? ToAngle(float value)
Parameters
valuefloatA stored value.
Returns
Exceptions
- InvalidOperationException
The parameter isn't stored in degrees true.
ToLength(float)
public Length? ToLength(float value)
Parameters
valuefloatA stored value.
Returns
Exceptions
- InvalidOperationException
The parameter isn't stored in metres.
ToPeriod(float)
Reads a stored value as a period. Only for parameters in Seconds.
public TimeSpan? ToPeriod(float value)
Parameters
valuefloatA stored value.
Returns
Exceptions
- InvalidOperationException
The parameter isn't stored in seconds.
ToSpeed(float)
Reads a stored value as a Speed. Only for parameters in MetresPerSecond.
public Speed? ToSpeed(float value)
Parameters
valuefloatA stored value.
Returns
Exceptions
- InvalidOperationException
The parameter isn't stored in metres per second.
ToString()
Returns Id.
public override string ToString()