ArcGIS Runtime SDK for iOS: AGSNMEALocation Class Reference
ArcGIS Runtime SDK for iOS  100.15
AGSNMEALocation Class Reference

Description

An NMEA location instance.

Contains information about parsed NMEA location.

Since
100.10
Inheritance diagram for AGSNMEALocation:
AGSLocation AGSObject

Instance Methods

(instancetype) - initWithPosition:horizontalAccuracy:velocity:course:lastKnown:
 
(instancetype) - initWithPosition:timestamp:horizontalAccuracy:verticalAccuracy:velocity:course:lastKnown:
 
(instancetype) - initWithPosition:timestamp:horizontalAccuracy:verticalAccuracy:velocity:course:lastKnown:additionalSourceProperties:
 

Class Methods

(AGSLocation *) + locationWithCLLocation:
 
(instancetype) + locationWithPosition:horizontalAccuracy:velocity:course:lastKnown:
 
(instancetype) + locationWithPosition:timestamp:horizontalAccuracy:verticalAccuracy:velocity:course:lastKnown:
 
(instancetype) + locationWithPosition:timestamp:horizontalAccuracy:verticalAccuracy:velocity:course:lastKnown:additionalSourceProperties:
 

Properties

AGSNMEAAccuracyType accuracyType
 
NSDictionary< AGSLocationSourcePropertyKey, id > * additionalSourceProperties
 
double course
 
NSTimeInterval DGPSAge
 
AGSNMEAFixType fixType
 
double geoidalSeparation
 
double HDOP
 
double heightAboveGeoid
 
double horizontalAccuracy
 
BOOL lastKnown
 
double PDOP
 
AGSPointposition
 
AGSPointreceivedPosition
 
NSInteger referenceStationID
 
NSArray< AGSNMEASatelliteInfo * > * satellites
 
NSDate * timestamp
 
double VDOP
 
double velocity
 
double verticalAccuracy
 

Method Documentation

◆ initWithPosition:horizontalAccuracy:velocity:course:lastKnown:

- (instancetype) initWithPosition: (AGSPoint *)  position
horizontalAccuracy: (double)  horizontalAccuracy
velocity: (double)  velocity
course: (double)  course
lastKnown: (BOOL)  lastKnown 

Creates a location update with provided information.

Parameters
positionThe coordinates of the location.
horizontalAccuracyThe radius of uncertainty for the location, measured in meters.
velocityThe velocity at which the device is traveling in meters per second.
courseThe direction in which the device is traveling, measured in degrees starting at due north and continuing clockwise around the compass.
lastKnownIndicates whether this is an outdated device position retrieved and cached earlier and therefore not guaranteed to represent the current location. Setting this to YES will render with the AGSLocationDisplay::acquiringSymbol, typically a grayed out location symbol.
Since
100

◆ initWithPosition:timestamp:horizontalAccuracy:verticalAccuracy:velocity:course:lastKnown:

- (instancetype) initWithPosition: (AGSPoint *)  position
timestamp: (NSDate *)  timestamp
horizontalAccuracy: (double)  horizontalAccuracy
verticalAccuracy: (double)  verticalAccuracy
velocity: (double)  velocity
course: (double)  course
lastKnown: (BOOL)  lastKnown 

Creates a location update with the provided information.

Parameters
positionThe coordinates of the location.
timestampThe date and time the location was determined.
horizontalAccuracyThe radius of uncertainty for the location, measured in meters.
verticalAccuracyThe accuracy of the vertical component of the location, measured in meters.
velocityThe velocity at which the device is traveling in meters per second.
courseThe direction in which the device is traveling, measured in degrees starting at due north and continuing clockwise around the compass.
lastKnownIndicates whether this is an outdated device position retrieved and cached earlier and therefore not guaranteed to represent the current location. Setting this to YES will render with the AGSLocationDisplay::acquiringSymbol, typically a grayed out location symbol.
Since
100.2.1

◆ initWithPosition:timestamp:horizontalAccuracy:verticalAccuracy:velocity:course:lastKnown:additionalSourceProperties:

- (instancetype) initWithPosition: (AGSPoint *)  position
timestamp: (nullable NSDate *)  timestamp
horizontalAccuracy: (double)  horizontalAccuracy
verticalAccuracy: (double)  verticalAccuracy
velocity: (double)  velocity
course: (double)  course
lastKnown: (BOOL)  lastKnown
additionalSourceProperties: (NSDictionary< AGSLocationSourcePropertyKey, id > *)  additionalSourceProperties 

Creates a location object with timestamp and additional source properties.

An AGSLocation object can be created from a variety of sources and using different technologies. By supplying the AGSLocation::additionalSourceProperties property you can allow users to find out how the data was captured.

Information should be provided as an NSDictionary of key-value pairs, where the AGSLocationSourceProperty key describes the type of data held in the id value. You can use any string for the key - but the Runtime SDK recognizes a number of well known keys which should be used if available. See AGSLocationSourcePropertyKey.

  • "floor" - The floor number of the AGSLocation object when in a building. Use AGSLocationSourcePropertyKeyFloor. This key should be associated with an NSNumber.
  • "satelliteCount" - The number of satellites used to fix the AGSLocation. Use AGSLocationSourcePropertyKeySatelliteCount. This key should be associated with an NSNumber.
  • "positionSource" - This key can be used to indicate the position source: GNSS, BLE, WIFI, CELL, IP, where GNSS indicates global navigation satellite system. It is possible to have multiple position sources. In that case positionSource is a list with comma-separated values. Use AGSLocationSourcePropertyKeyPositionSource. This key should be associated with an NSString.
  • "transmitterCount" - The number of transmitters used to create an indoor positioning system (IPS) position. Use AGSLocationSourcePropertyKeyTransmitterCount. This key should be associated with an NSNumber.

Keys are case-sensitive.

Parameters
positionA point geometry.
timestampA timestamp when location was received.
horizontalAccuracyThe horizontal accuracy in meters. Positive values or NaN are supported.
verticalAccuracyThe vertical accuracy in meters. Positive values or NaN are supported.
velocityThe location's velocity in meters per second.
courseThe location's course in degrees (clockwise), 0 being true north.
lastKnownIndicates whether this is an outdated device position retrieved and cached earlier and therefore not guaranteed to represent the current location. Setting this to YES will render with the AGSLocationDisplay::acquiringSymbol property, typically a grayed out location symbol.
additionalSourcePropertiesAn NSDictionary of key-value pairs providing additional meta-data and properties about the source of this AGSLocation object.
See also
AGSLocation::additionalSourceProperties
Since
100.10

◆ locationWithCLLocation:

+ (AGSLocation*) locationWithCLLocation: (CLLocation *)  cllocation

Creates a location update with the provided information.

Note
If the provided CLLocation object has a timestamp more than 30 seconds in the past, the returned AGSLocation object will have lastKnown set to YES, otherwise it will be considered current and lastKnown will be NO.
Parameters
cllocationA CLLocation object representing the location data generated by CLLocationManager.
Returns
A new location object.
Since
100

◆ locationWithPosition:horizontalAccuracy:velocity:course:lastKnown:

+ (instancetype) locationWithPosition: (AGSPoint *)  position
horizontalAccuracy: (double)  horizontalAccuracy
velocity: (double)  velocity
course: (double)  course
lastKnown: (BOOL)  lastKnown 

Creates a location update with the provided information.

Parameters
positionThe coordinates of the location.
horizontalAccuracyThe radius of uncertainty for the location, measured in meters.
velocityThe velocity at which the device is traveling in meters per second.
courseThe direction in which the device is traveling, measured in degrees starting at due north and continuing clockwise around the compass.
lastKnownIndicates whether the information is current or based on a last known update (for example, in the case of deferred location updates).
Returns
A new location object.
Since
100

◆ locationWithPosition:timestamp:horizontalAccuracy:verticalAccuracy:velocity:course:lastKnown:

+ (instancetype) locationWithPosition: (AGSPoint *)  position
timestamp: (NSDate *)  timestamp
horizontalAccuracy: (double)  horizontalAccuracy
verticalAccuracy: (double)  verticalAccuracy
velocity: (double)  velocity
course: (double)  course
lastKnown: (BOOL)  lastKnown 

Creates a location update with the provided information.

Parameters
positionThe coordinates of the location.
timestampThe date and time the location was determined.
horizontalAccuracyThe radius of uncertainty for the location, measured in meters.
verticalAccuracyThe accuracy of the vertical component of the location, measured in meters.
velocityThe velocity at which the device is traveling in meters per second
courseThe direction in which the device is traveling, measured in degrees starting at due north and continuing clockwise around the compass.
lastKnownIndicates whether this is an outdated device position retrieved and cached earlier and therefore not guaranteed to represent the current location. Setting this to YES will render with the AGSLocationDisplay::acquiringSymbol property, typically a grayed out location symbol.
Returns
A new location object.
Since
100.2.1

◆ locationWithPosition:timestamp:horizontalAccuracy:verticalAccuracy:velocity:course:lastKnown:additionalSourceProperties:

+ (instancetype) locationWithPosition: (AGSPoint *)  position
timestamp: (nullable NSDate *)  timestamp
horizontalAccuracy: (double)  horizontalAccuracy
verticalAccuracy: (double)  verticalAccuracy
velocity: (double)  velocity
course: (double)  course
lastKnown: (BOOL)  lastKnown
additionalSourceProperties: (NSDictionary< AGSLocationSourcePropertyKey, id > *)  additionalSourceProperties 

Creates a location object with timestamp and additional source properties.

An AGSLocation object can be created from a variety of sources and using different technologies. By supplying the AGSLocation::additionalSourceProperties property you can allow users to find out how the data was captured.

Information should be provided as an NSDictionary of key-value pairs, where the AGSLocationSourceProperty key describes the type of data held in the id value. You can use any string for the key - but the Runtime SDK recognizes a number of well known keys which should be used if available. See AGSLocationSourcePropertyKey.

  • "floor" - The floor number of the AGSLocation when in a building. Use AGSLocationSourcePropertyKeyFloor. This key should be associated with an NSNumber.
  • "satelliteCount" - The number of satellites used to fix the AGSLocation object. Use AGSLocationSourcePropertyKeySatelliteCount. This key should be associated with an NSNumber.
  • "positionSource" - This key can be used to indicate the position source: GNSS, BLE, WIFI, CELL, IP, where GNSS indicates global navigation satellite system. It is possible to have multiple position sources. In that case positionSource is a list with comma-separated values. Use AGSLocationSourcePropertyKeyPositionSource. This key should be associated with an NSString.
  • "transmitterCount" - The number of transmitters used to create an indoor positioning system (IPS) position. Use AGSLocationSourcePropertyKeyTransmitterCount. This key should be associated with an NSNumber.

Keys are case-sensitive.

Parameters
positionA point geometry.
timestampA timestamp when location was received.
horizontalAccuracyThe horizontal accuracy in meters. Positive values or NaN are supported.
verticalAccuracyThe vertical accuracy in meters. Positive values or NaN are supported.
velocityThe location's velocity in meters per second.
courseThe location's course in degrees (clockwise), 0 being true north.
lastKnownIndicates whether this is an outdated device position retrieved and cached earlier and therefore not guaranteed to represent the current location. Setting this to YES will render with the AGSLocationDisplay::acquiringSymbol, typically a grayed out location symbol.
additionalSourcePropertiesAn NSDictionary of key-value pairs providing additional meta-data and properties about the source of this AGSLocation.
Returns
A new location object.
See also
AGSLocation::additionalSourceProperties
Since
100.10

Property Documentation

◆ accuracyType

- (AGSNMEAAccuracyType) accuracyType
readnonatomicassign

The accuracy type of the location.

Since
100.10

◆ additionalSourceProperties

- (NSDictionary<AGSLocationSourcePropertyKey, id>*) additionalSourceProperties
readnonatomiccopyinherited

A set of key-value pairs providing additional meta-data and properties about the source of this AGSLocation object.

An AGSLocation object can be created manually or by a variety of AGSLocationDataSource types

  • for example from the default platform data source or external GPS. When user code receives a new AGSLocation object, it can be important to determine how the information was obtained.

In addition, mobile devices may provide different details about their in-built location services. For example, Android systems can provide data on the number of satellites used to find a position, whereas on iOS this information is not available. When a given property is not available to the data source the entry should be omitted from the the AGSLocation::additionalSourceProperties property.

The AGSLocation::additionalSourceProperties property provides a means for the creator of an AGSLocation object to record flexible information such as:

  • The confidence level associated with the location
  • The method used to obtain the location
  • The provenance of the location

Information should be provided as an NSDictionary of key-value pairs, where the NSString key describes the type of data held in the id value. You can use any string for the key - but the Runtime SDK recognizes a number of well known keys which should be used if available. See AGSLocationSourcePropertyKey.

  • "floor" - The floor number of the AGSLocation when in a building. Use AGSLocationSourcePropertyKeyFloor. This key should be associated with an NSNumber.
  • "satelliteCount" - The number of satellites used to fix the AGSLocation. Use AGSLocationSourcePropertyKeySatelliteCount. This key should be associated with an NSNumber.
  • "positionSource" - This key can be used to indicate the position source: GNSS, BLE, WIFI, CELL, IP, where GNSS indicates global navigation satellite system. It is possible to have multiple position sources. In that case positionSource is a list with comma-separated values. Use AGSLocationSourcePropertyKeyPositionSource. This key should be associated with an NSString.
  • "transmitterCount" - The number of transmitters used to create an indoor positioning system (IPS) position. Use AGSLocationSourcePropertyKeyTransmitterCount. This key should be associated with an NSNumber.

Keys are case-sensitive.

Since
100.10

◆ course

- (double) course
readnonatomicassigninherited

The direction in which the device is traveling, measured in degrees starting at due north and continuing clockwise around the compass. Thus, north is 0 degrees, east is 90 degrees, south is 180 degrees, and so on. Course values may not be available on all devices. A negative value indicates that the direction is invalid.

Since
100

◆ DGPSAge

- (NSTimeInterval) DGPSAge
readnonatomicassign

The DGPS age of the location.

This shows the age of the differential data and the time elapsed since the last valid differential correction received. Because the validity of a differential correction depends on the difference between the time the differential signal is calculated and the time it is used by the receiver, smaller values are better.

Since
100.10

◆ fixType

- (AGSNMEAFixType) fixType
readnonatomicassign

The fix type of the location.

See also
AGSNMEAFixType
Since
100.10

◆ geoidalSeparation

- (double) geoidalSeparation
readnonatomicassign

The geoidal separation in meters.

Since
100.10

◆ HDOP

- (double) HDOP
readnonatomicassign

The HDOP (horizontal dilution of precision) of the location, 0.5 through 99.9.

Since
100.10

◆ heightAboveGeoid

- (double) heightAboveGeoid
readnonatomicassign

The height above the geoid surface in meters.

Since
100.10

◆ horizontalAccuracy

- (double) horizontalAccuracy
readnonatomicassigninherited

The radius of uncertainty for the location, measured in meters. The location’s position property identifies the center of the circle, and this value indicates the radius of that circle. A negative value indicates that the location’s position is invalid.

Since
100

◆ lastKnown

- (BOOL) lastKnown
readnonatomicassigninherited

Indicates whether this is an outdated device position retrieved and cached earlier and therefore not guaranteed to represent the current location.

Since
100

◆ PDOP

- (double) PDOP
readnonatomicassign

The PDOP (positional dilution of precision) of the location 0.5 through 99.9.

Since
100.10

◆ position

- (AGSPoint*) position
readnonatomicstronginherited

The coordinates of the location.

Since
100

◆ receivedPosition

- (AGSPoint*) receivedPosition
readnonatomicstrong

The position originally returned by the receiver.

If the incoming data was projected this position may differ from the AGSNMEALocation::position property.

Since
100.10

◆ referenceStationID

- (NSInteger) referenceStationID
readnonatomicassign

The reference station ID of the location.

Since
100.10

◆ satellites

- (NSArray<AGSNMEASatelliteInfo *>*) satellites
readnonatomiccopy

The satellites info of the location.

Since
100.10

◆ timestamp

- (NSDate*) timestamp
readnonatomicstronginherited

The time the location was determined.

Since
100.2.1

◆ VDOP

- (double) VDOP
readnonatomicassign

The VDOP (vertical dilution of precision) of the location, 0.5 through 99.9.

Since
100.10

◆ velocity

- (double) velocity
readnonatomicassigninherited

The instantaneous speed of the device in meters per second.

Since
100

◆ verticalAccuracy

- (double) verticalAccuracy
readnonatomicassigninherited

The accuracy of the location's vertical component, in meters.

Since
100.2.1