Class GpxWaypoint
Represents a waypoint, point of interest, or named feature on a map.
Inherited Members
Namespace: NetTopologySuite.IO
Assembly: NetTopologySuite.IO.GPX.dll
Syntax
public sealed class GpxWaypoint
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the simple type "wptType".
Constructors
| Improve this Doc View SourceGpxWaypoint(Coordinate)
Initializes a new instance of the GpxWaypoint class.
Declaration
public GpxWaypoint(Coordinate coordinate)
Parameters
Type | Name | Description |
---|---|---|
Coordinate | coordinate |
Remarks
Exceptions
Type | Condition |
---|---|
ArgumentNullException | Thrown when |
ArgumentException | Thrown when:
|
GpxWaypoint(GpxLongitude, GpxLatitude)
Initializes a new instance of the GpxWaypoint class.
Declaration
public GpxWaypoint(GpxLongitude longitude, GpxLatitude latitude)
Parameters
Type | Name | Description |
---|---|---|
GpxLongitude | longitude | The value for Longitude. |
GpxLatitude | latitude | The value for Latitude. |
GpxWaypoint(GpxLongitude, GpxLatitude, Nullable<Double>)
Initializes a new instance of the GpxWaypoint class.
Declaration
public GpxWaypoint(GpxLongitude longitude, GpxLatitude latitude, double? elevationInMeters)
Parameters
Type | Name | Description |
---|---|---|
GpxLongitude | longitude | The value for Longitude. |
GpxLatitude | latitude | The value for Latitude. |
Nullable<Double> | elevationInMeters | The value for ElevationInMeters. |
Exceptions
Type | Condition |
---|---|
ArgumentOutOfRangeException | Thrown when |
GpxWaypoint(GpxLongitude, GpxLatitude, Nullable<Double>, Nullable<DateTime>, Nullable<GpxDegrees>, Nullable<Double>, String, String, String, String, ImmutableArray<GpxWebLink>, String, String, Nullable<GpxFixKind>, Nullable<UInt32>, Nullable<Double>, Nullable<Double>, Nullable<Double>, Nullable<Double>, Nullable<GpxDgpsStationId>, Object)
Initializes a new instance of the GpxWaypoint class.
Declaration
public GpxWaypoint(GpxLongitude longitude, GpxLatitude latitude, double? elevationInMeters, DateTime? timestampUtc, GpxDegrees? magneticVariation, double? geoidHeight, string name, string comment, string description, string source, ImmutableArray<GpxWebLink> links, string symbolText, string classification, GpxFixKind? fixKind, uint? numberOfSatellites, double? horizontalDilutionOfPrecision, double? verticalDilutionOfPrecision, double? positionDilutionOfPrecision, double? secondsSinceLastDgpsUpdate, GpxDgpsStationId? dgpsStationId, object extensions)
Parameters
Type | Name | Description |
---|---|---|
GpxLongitude | longitude | The value for Longitude. |
GpxLatitude | latitude | The value for Latitude. |
Nullable<Double> | elevationInMeters | The value for ElevationInMeters. |
Nullable<DateTime> | timestampUtc | The value for TimestampUtc. |
Nullable<GpxDegrees> | magneticVariation | The value for MagneticVariation. |
Nullable<Double> | geoidHeight | The value for GeoidHeight. |
String | name | The value for Name. |
String | comment | The value for Comment. |
String | description | The value for Description. |
String | source | The value for Source. |
ImmutableArray<GpxWebLink> | links | The value for Links. |
String | symbolText | The value for SymbolText. |
String | classification | The value for Classification. |
Nullable<GpxFixKind> | fixKind | The value for FixKind. |
Nullable<UInt32> | numberOfSatellites | The value for NumberOfSatellites. |
Nullable<Double> | horizontalDilutionOfPrecision | The value for HorizontalDilutionOfPrecision. |
Nullable<Double> | verticalDilutionOfPrecision | The value for VerticalDilutionOfPrecision. |
Nullable<Double> | positionDilutionOfPrecision | The value for PositionDilutionOfPrecision. |
Nullable<Double> | secondsSinceLastDgpsUpdate | The value for SecondsSinceLastDgpsUpdate. |
Nullable<GpxDgpsStationId> | dgpsStationId | The value for DgpsStationId. |
Object | extensions | The value for Extensions. |
Exceptions
Type | Condition |
---|---|
ArgumentOutOfRangeException | Thrown when: |
Properties
| Improve this Doc View SourceClassification
Gets the classification of this location.
Declaration
public string Classification { get; }
Property Value
Type | Description |
---|---|
String |
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the "type" element.
Comment
Gets the GPS comment of this location, to be transferred to and from the GPS.
Declaration
public string Comment { get; }
Property Value
Type | Description |
---|---|
String |
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the "cmt" element.
Description
Gets an additional text description for this location for the user (not the GPS).
Declaration
public string Description { get; }
Property Value
Type | Description |
---|---|
String |
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the "desc" element.
DgpsStationId
Gets the ID of the DGPS station used in differential correction.
Declaration
public GpxDgpsStationId? DgpsStationId { get; }
Property Value
Type | Description |
---|---|
Nullable<GpxDgpsStationId> |
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the "dgpsid" element.
ElevationInMeters
Gets the elevation of this point, in meters.
Declaration
public double? ElevationInMeters { get; }
Property Value
Type | Description |
---|---|
Nullable<Double> |
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the "ele" element.
Extensions
Gets arbitrary extension information associated with this waypoint.
Declaration
public object Extensions { get; }
Property Value
Type | Description |
---|---|
Object |
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the "extensions" element.
FixKind
Gets the type of fix when this waypoint was generated.
Declaration
public GpxFixKind? FixKind { get; }
Property Value
Type | Description |
---|---|
Nullable<GpxFixKind> |
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the "fix" element.
GeoidHeight
Gets the height (in meters) of geoid (mean sea level) above WGS84 earth ellipsoid at this location, as defined in NMEA GGA message.
Declaration
public double? GeoidHeight { get; }
Property Value
Type | Description |
---|---|
Nullable<Double> |
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the "geoidheight" element.
HorizontalDilutionOfPrecision
Gets the horizontal dilution of precision.
Declaration
public double? HorizontalDilutionOfPrecision { get; }
Property Value
Type | Description |
---|---|
Nullable<Double> |
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the "hdop" element.
Latitude
Gets the latitude of this location, in decimal degrees (WGS84).
Declaration
public GpxLatitude Latitude { get; }
Property Value
Type | Description |
---|---|
GpxLatitude |
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the "lat" attribute.
Links
Gets links to additional information about this location.
Declaration
public ImmutableArray<GpxWebLink> Links { get; }
Property Value
Type | Description |
---|---|
ImmutableArray<GpxWebLink> |
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the "link" elements.
Longitude
Gets the longitude of this location, in decimal degrees (WGS84).
Declaration
public GpxLongitude Longitude { get; }
Property Value
Type | Description |
---|---|
GpxLongitude |
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the "lon" attribute.
MagneticVariation
Gets the magnetic variation at this location.
Declaration
public GpxDegrees? MagneticVariation { get; }
Property Value
Type | Description |
---|---|
Nullable<GpxDegrees> |
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the "magvar" element.
Name
Gets the GPS name of this location, to be transferred to and from the GPS.
Declaration
public string Name { get; }
Property Value
Type | Description |
---|---|
String |
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the "name" element.
NumberOfSatellites
Gets the number of satellites used to calculate the GPS fix.
Declaration
public uint? NumberOfSatellites { get; }
Property Value
Type | Description |
---|---|
Nullable<UInt32> |
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the "sat" element.
PositionDilutionOfPrecision
Gets the position dilution of precision.
Declaration
public double? PositionDilutionOfPrecision { get; }
Property Value
Type | Description |
---|---|
Nullable<Double> |
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the "pdop" element.
SecondsSinceLastDgpsUpdate
Gets the number of seconds since the last DGPS update when this waypoint was generated.
Declaration
public double? SecondsSinceLastDgpsUpdate { get; }
Property Value
Type | Description |
---|---|
Nullable<Double> |
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the "ageofdgpsdata" element.
Source
Gets the source of the data, e.g., "Garmin eTrex", "USGS quad Boston North".
Declaration
public string Source { get; }
Property Value
Type | Description |
---|---|
String |
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the "src" element.
SymbolText
Gets the text of the GPS symbol name for this location.
Declaration
public string SymbolText { get; }
Property Value
Type | Description |
---|---|
String |
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the "sym" element.
TimestampUtc
Gets the creation / modification timestamp of this location, in UTC time.
Declaration
public DateTime? TimestampUtc { get; }
Property Value
Type | Description |
---|---|
Nullable<DateTime> |
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the "time" element.
VerticalDilutionOfPrecision
Gets the vertical dilution of precision.
Declaration
public double? VerticalDilutionOfPrecision { get; }
Property Value
Type | Description |
---|---|
Nullable<Double> |
Remarks
In the official XSD schema for GPX 1.1, this corresponds to the "vdop" element.
Methods
| Improve this Doc View SourceEquals(Object)
Declaration
public override bool Equals(object obj)
Parameters
Type | Name | Description |
---|---|---|
Object | obj |
Returns
Type | Description |
---|---|
Boolean |
Overrides
| Improve this Doc View SourceGetHashCode()
Declaration
public override int GetHashCode()
Returns
Type | Description |
---|---|
Int32 |
Overrides
| Improve this Doc View SourceToString()
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
String |
Overrides
| Improve this Doc View SourceWithClassification(String)
Builds a new instance of GpxWaypoint as a copy of this instance, but with Classification replaced by the given value.
Declaration
public GpxWaypoint WithClassification(string classification)
Parameters
Type | Name | Description |
---|---|---|
String | classification | The new value for Classification. |
Returns
Type | Description |
---|---|
GpxWaypoint | A new GpxWaypoint instance that's a copy of the current instance, but
with its Classification value set to |
WithComment(String)
Builds a new instance of GpxWaypoint as a copy of this instance, but with Comment replaced by the given value.
Declaration
public GpxWaypoint WithComment(string comment)
Parameters
Type | Name | Description |
---|---|---|
String | comment | The new value for Comment. |
Returns
Type | Description |
---|---|
GpxWaypoint | A new GpxWaypoint instance that's a copy of the current instance, but
with its Comment value set to |
WithDescription(String)
Builds a new instance of GpxWaypoint as a copy of this instance, but with Description replaced by the given value.
Declaration
public GpxWaypoint WithDescription(string description)
Parameters
Type | Name | Description |
---|---|---|
String | description | The new value for Description. |
Returns
Type | Description |
---|---|
GpxWaypoint | A new GpxWaypoint instance that's a copy of the current instance, but
with its Description value set to |
WithDgpsStationId(Nullable<GpxDgpsStationId>)
Builds a new instance of GpxWaypoint as a copy of this instance, but with DgpsStationId replaced by the given value.
Declaration
public GpxWaypoint WithDgpsStationId(GpxDgpsStationId? dgpsStationId)
Parameters
Type | Name | Description |
---|---|---|
Nullable<GpxDgpsStationId> | dgpsStationId | The new value for DgpsStationId. |
Returns
Type | Description |
---|---|
GpxWaypoint | A new GpxWaypoint instance that's a copy of the current instance, but
with its DgpsStationId value set to |
WithElevationInMeters(Nullable<Double>)
Builds a new instance of GpxWaypoint as a copy of this instance, but with ElevationInMeters replaced by the given value.
Declaration
public GpxWaypoint WithElevationInMeters(double? elevationInMeters)
Parameters
Type | Name | Description |
---|---|---|
Nullable<Double> | elevationInMeters | The new value for ElevationInMeters. |
Returns
Type | Description |
---|---|
GpxWaypoint | A new GpxWaypoint instance that's a copy of the current instance, but
with its ElevationInMeters value set to |
Exceptions
Type | Condition |
---|---|
ArgumentException | Thrown when |
WithExtensions(Object)
Builds a new instance of GpxWaypoint as a copy of this instance, but with Extensions replaced by the given value.
Declaration
public GpxWaypoint WithExtensions(object extensions)
Parameters
Type | Name | Description |
---|---|---|
Object | extensions | The new value for Extensions. |
Returns
Type | Description |
---|---|
GpxWaypoint | A new GpxWaypoint instance that's a copy of the current instance, but
with its Extensions value set to |
WithFixKind(Nullable<GpxFixKind>)
Builds a new instance of GpxWaypoint as a copy of this instance, but with FixKind replaced by the given value.
Declaration
public GpxWaypoint WithFixKind(GpxFixKind? fixKind)
Parameters
Type | Name | Description |
---|---|---|
Nullable<GpxFixKind> | fixKind | The new value for FixKind. |
Returns
Type | Description |
---|---|
GpxWaypoint | A new GpxWaypoint instance that's a copy of the current instance, but
with its FixKind value set to |
WithGeoidHeight(Nullable<Double>)
Builds a new instance of GpxWaypoint as a copy of this instance, but with GeoidHeight replaced by the given value.
Declaration
public GpxWaypoint WithGeoidHeight(double? geoidHeight)
Parameters
Type | Name | Description |
---|---|---|
Nullable<Double> | geoidHeight | The new value for GeoidHeight. |
Returns
Type | Description |
---|---|
GpxWaypoint | A new GpxWaypoint instance that's a copy of the current instance, but
with its GeoidHeight value set to |
WithHorizontalDilutionOfPrecision(Nullable<Double>)
Builds a new instance of GpxWaypoint as a copy of this instance, but with HorizontalDilutionOfPrecision replaced by the given value.
Declaration
public GpxWaypoint WithHorizontalDilutionOfPrecision(double? horizontalDilutionOfPrecision)
Parameters
Type | Name | Description |
---|---|---|
Nullable<Double> | horizontalDilutionOfPrecision | The new value for HorizontalDilutionOfPrecision. |
Returns
Type | Description |
---|---|
GpxWaypoint | A new GpxWaypoint instance that's a copy of the current instance, but
with its HorizontalDilutionOfPrecision value set to |
WithLatitude(GpxLatitude)
Builds a new instance of GpxWaypoint as a copy of this instance, but with Latitude replaced by the given value.
Declaration
public GpxWaypoint WithLatitude(GpxLatitude latitude)
Parameters
Type | Name | Description |
---|---|---|
GpxLatitude | latitude | The new value for Latitude. |
Returns
Type | Description |
---|---|
GpxWaypoint | A new GpxWaypoint instance that's a copy of the current instance, but
with its Latitude value set to |
WithLinks(ImmutableArray<GpxWebLink>)
Builds a new instance of GpxWaypoint as a copy of this instance, but with Links replaced by the given value.
Declaration
public GpxWaypoint WithLinks(ImmutableArray<GpxWebLink> links)
Parameters
Type | Name | Description |
---|---|---|
ImmutableArray<GpxWebLink> | links | The new value for Links. |
Returns
Type | Description |
---|---|
GpxWaypoint | A new GpxWaypoint instance that's a copy of the current instance, but
with its Links value set to |
WithLongitude(GpxLongitude)
Builds a new instance of GpxWaypoint as a copy of this instance, but with Longitude replaced by the given value.
Declaration
public GpxWaypoint WithLongitude(GpxLongitude longitude)
Parameters
Type | Name | Description |
---|---|---|
GpxLongitude | longitude | The new value for Longitude. |
Returns
Type | Description |
---|---|
GpxWaypoint | A new GpxWaypoint instance that's a copy of the current instance, but
with its Longitude value set to |
WithMagneticVariation(Nullable<GpxDegrees>)
Builds a new instance of GpxWaypoint as a copy of this instance, but with MagneticVariation replaced by the given value.
Declaration
public GpxWaypoint WithMagneticVariation(GpxDegrees? magneticVariation)
Parameters
Type | Name | Description |
---|---|---|
Nullable<GpxDegrees> | magneticVariation | The new value for MagneticVariation. |
Returns
Type | Description |
---|---|
GpxWaypoint | A new GpxWaypoint instance that's a copy of the current instance, but
with its MagneticVariation value set to |
WithName(String)
Builds a new instance of GpxWaypoint as a copy of this instance, but with Name replaced by the given value.
Declaration
public GpxWaypoint WithName(string name)
Parameters
Type | Name | Description |
---|---|---|
String | name | The new value for Name. |
Returns
Type | Description |
---|---|
GpxWaypoint | A new GpxWaypoint instance that's a copy of the current instance, but
with its Name value set to |
WithNumberOfSatellites(Nullable<UInt32>)
Builds a new instance of GpxWaypoint as a copy of this instance, but with NumberOfSatellites replaced by the given value.
Declaration
public GpxWaypoint WithNumberOfSatellites(uint? numberOfSatellites)
Parameters
Type | Name | Description |
---|---|---|
Nullable<UInt32> | numberOfSatellites | The new value for NumberOfSatellites. |
Returns
Type | Description |
---|---|
GpxWaypoint | A new GpxWaypoint instance that's a copy of the current instance, but
with its NumberOfSatellites value set to |
WithPositionDilutionOfPrecision(Nullable<Double>)
Builds a new instance of GpxWaypoint as a copy of this instance, but with PositionDilutionOfPrecision replaced by the given value.
Declaration
public GpxWaypoint WithPositionDilutionOfPrecision(double? positionDilutionOfPrecision)
Parameters
Type | Name | Description |
---|---|---|
Nullable<Double> | positionDilutionOfPrecision | The new value for PositionDilutionOfPrecision. |
Returns
Type | Description |
---|---|
GpxWaypoint | A new GpxWaypoint instance that's a copy of the current instance, but
with its PositionDilutionOfPrecision value set to |
WithSecondsSinceLastDgpsUpdate(Nullable<Double>)
Builds a new instance of GpxWaypoint as a copy of this instance, but with SecondsSinceLastDgpsUpdate replaced by the given value.
Declaration
public GpxWaypoint WithSecondsSinceLastDgpsUpdate(double? secondsSinceLastDgpsUpdate)
Parameters
Type | Name | Description |
---|---|---|
Nullable<Double> | secondsSinceLastDgpsUpdate | The new value for SecondsSinceLastDgpsUpdate. |
Returns
Type | Description |
---|---|
GpxWaypoint | A new GpxWaypoint instance that's a copy of the current instance, but
with its SecondsSinceLastDgpsUpdate value set to |
WithSource(String)
Builds a new instance of GpxWaypoint as a copy of this instance, but with Source replaced by the given value.
Declaration
public GpxWaypoint WithSource(string source)
Parameters
Type | Name | Description |
---|---|---|
String | source | The new value for Source. |
Returns
Type | Description |
---|---|
GpxWaypoint | A new GpxWaypoint instance that's a copy of the current instance, but
with its Source value set to |
WithSymbolText(String)
Builds a new instance of GpxWaypoint as a copy of this instance, but with SymbolText replaced by the given value.
Declaration
public GpxWaypoint WithSymbolText(string symbolText)
Parameters
Type | Name | Description |
---|---|---|
String | symbolText | The new value for SymbolText. |
Returns
Type | Description |
---|---|
GpxWaypoint | A new GpxWaypoint instance that's a copy of the current instance, but
with its SymbolText value set to |
WithTimestampUtc(Nullable<DateTime>)
Builds a new instance of GpxWaypoint as a copy of this instance, but with TimestampUtc replaced by the given value.
Declaration
public GpxWaypoint WithTimestampUtc(DateTime? timestampUtc)
Parameters
Type | Name | Description |
---|---|---|
Nullable<DateTime> | timestampUtc | The new value for TimestampUtc. |
Returns
Type | Description |
---|---|
GpxWaypoint | A new GpxWaypoint instance that's a copy of the current instance, but
with its TimestampUtc value set to |
Exceptions
Type | Condition |
---|---|
ArgumentException | Thrown when |
WithVerticalDilutionOfPrecision(Nullable<Double>)
Builds a new instance of GpxWaypoint as a copy of this instance, but with VerticalDilutionOfPrecision replaced by the given value.
Declaration
public GpxWaypoint WithVerticalDilutionOfPrecision(double? verticalDilutionOfPrecision)
Parameters
Type | Name | Description |
---|---|---|
Nullable<Double> | verticalDilutionOfPrecision | The new value for VerticalDilutionOfPrecision. |
Returns
Type | Description |
---|---|
GpxWaypoint | A new GpxWaypoint instance that's a copy of the current instance, but
with its VerticalDilutionOfPrecision value set to |