SYPositioningManager Class Reference

Manages positioning services for the Sygic SDK. More...

#import <SYPositioning.h>

Inheritance diagram for SYPositioningManager:
Collaboration diagram for SYPositioningManager:

Public Types

typedef void(^ SYRoadDetailsCompletionBlock) (SYMapMatchingResult result, NSArray< SYRoadDetail * > *_Nullable roads)
 

Instance Methods

((unavailable("Use +[SYPositioningManager shared] instead.") - __attribute__
 SYPositioningManager is singleton, use [SYPositioningManager shared] to access singleton instance. More...
 
(void) - startUpdatingPositionWithCompletion:
 Start updating position. Affects all SYPositioning instances. More...
 
(void) - stopUpdatingPositionWithCompletion:
 Stop updating position. Affects all SYPositioning instances. More...
 
(void) - startPositionLoggingNmeaWithReceiverBlock:completion:
 
(void) - stopPositionLoggingNmeaWithCompletion:
 
(nonnull SYPositionDataSource *) - getDataSource
 Get current provider of raw position data for the positioning manager. If you didnt set datasource, a default instance of SYDevicePositionSource is returned. More...
 
(void) - setDataSource:completion:
 Set current provider of raw position data for the positioning manager. If positioning is started with a nil dataSource, a default instance of SYDevicePositionSource is created and installed. More...
 
(void) - matchPositions:precisions:timestamps:completion:
 Map matching algorithm, tries to create continuous road sequence of roads representing provided polyline. More...
 
(void) - projectMatchedGeometryForPositions:matchedIds:tolerance:completion:
 Matches provided geometry to road sequence. Result should contain array of SYMatchedRoad with same size as input positions. Each position is matched to one of roads from ids with tollerance. Not all SYMatchedRoadId from input may be in result array and some of them may be there multiple times with different distances. More...
 
(void) - getRoadDetailsForIds:completion:
 Provides details for set of roads. More...
 
(void) - getTunnelPositioningModeWithCompletion:
 Asynchronously retrieves current tunnel position mode. More...
 
(void) - setTunnelPositioningMode:completion:
 Asynchronously sets current tunnel position mode. More...
 

Class Methods

(nullable SYPositioningManager *) + shared
 Returns the SYPositioningManager singleton instance (or nil if SygicMaps SDK is not initialized). More...
 
((unavailable("Use +[SYPositioningManager shared] instead.") + __attribute__
 

Detailed Description

Manages positioning services for the Sygic SDK.

Member Typedef Documentation

◆ SYRoadDetailsCompletionBlock

- (typedef void(^ SYRoadDetailsCompletionBlock) (SYMapMatchingResult result, NSArray< SYRoadDetail * > *_Nullable roads))

Method Documentation

◆ shared

+ (nullable SYPositioningManager*) shared

Returns the SYPositioningManager singleton instance (or nil if SygicMaps SDK is not initialized).

◆ __attribute__ [1/2]

- ((unavailable("Use +[SYPositioningManager shared] instead.") __attribute__

SYPositioningManager is singleton, use [SYPositioningManager shared] to access singleton instance.

◆ __attribute__ [2/2]

+ ((unavailable("Use +[SYPositioningManager shared] instead.") __attribute__

◆ startUpdatingPositionWithCompletion:

- (void) startUpdatingPositionWithCompletion: (nullable SYOperationDoneCompletionBlock)  completion

Start updating position. Affects all SYPositioning instances.

◆ stopUpdatingPositionWithCompletion:

- (void) stopUpdatingPositionWithCompletion: (nullable SYOperationDoneCompletionBlock)  completion

Stop updating position. Affects all SYPositioning instances.

◆ startPositionLoggingNmeaWithReceiverBlock:completion:

- (void) startPositionLoggingNmeaWithReceiverBlock: (nonnull SYPositionLogNMEASentenceBlock)  receiverBlock
completion: (nullable SYOperationDoneCompletionBlock)  completion 

Start position logging in NMEA format.

Parameters
receiverBlockCallback which will receive NMEA sentences, it will be called when position is updated.
completionCallback which will be called when logging is initialized and started.

◆ stopPositionLoggingNmeaWithCompletion:

- (void) stopPositionLoggingNmeaWithCompletion: (nullable SYOperationDoneCompletionBlock)  completion

Stop position logging in NMEA format.

Parameters
completionCallback which will be called when logging is stopped.

◆ getDataSource

- (nonnull SYPositionDataSource*) getDataSource

Get current provider of raw position data for the positioning manager. If you didnt set datasource, a default instance of SYDevicePositionSource is returned.

◆ setDataSource:completion:

- (void) setDataSource: (nullable SYPositionDataSource *)  source
completion: (nullable SYDataSourceCompletionBlock)  completion 

Set current provider of raw position data for the positioning manager. If positioning is started with a nil dataSource, a default instance of SYDevicePositionSource is created and installed.

◆ matchPositions:precisions:timestamps:completion:

- (void) matchPositions: (nonnull NSArray< SYGeoCoordinate * > *)  positions
precisions: (nullable NSArray< NSNumber * > *)  precisions
timestamps: (nullable NSArray< NSNumber * > *)  timestamps
completion: (nonnull SYMapMatchingMatchCompletionBlock)  completion 

Map matching algorithm, tries to create continuous road sequence of roads representing provided polyline.

Parameters
positionsArray of coordinates to be matched to the road geometry.
precisionsArray of precisions (optional), doubleValue of each element must represent the distance in meters for matching the corresponding position to the road geometry. Each element relates to the coordinate from the positions array at the same index.
timestampsArray of timestamps (optional), unsignedIntValue of each element must represent the time in seconds since Unix epoch for matching the corresponding position to the road geometry. Each element relates to the coordinate from the positions array at the same index.
completionCompletion block called asynchronously when the operation is finished.

◆ projectMatchedGeometryForPositions:matchedIds:tolerance:completion:

- (void) projectMatchedGeometryForPositions: (nonnull NSArray< SYGeoCoordinate * > *)  positions
matchedIds: (nonnull NSArray< SYRoadId * > *)  ids
tolerance: (SYAccuracy)  tolerance
completion: (nonnull SYMapMatchingProjectMatchedGeometryCompletionBlock)  completion 

Matches provided geometry to road sequence. Result should contain array of SYMatchedRoad with same size as input positions. Each position is matched to one of roads from ids with tollerance. Not all SYMatchedRoadId from input may be in result array and some of them may be there multiple times with different distances.

◆ getRoadDetailsForIds:completion:

- (void) getRoadDetailsForIds: (nonnull NSArray< SYRoadId * > *)  ids
completion: (nonnull SYRoadDetailsCompletionBlock completion 

Provides details for set of roads.

◆ getTunnelPositioningModeWithCompletion:

- (void) getTunnelPositioningModeWithCompletion: (nonnull SYGetTunnelPositioningModeBlock)  completion

Asynchronously retrieves current tunnel position mode.

◆ setTunnelPositioningMode:completion:

- (void) setTunnelPositioningMode: (SYTunnelPositioningMode)  mode
completion: (nonnull SYSetTunnelPositioningModeBlock)  completion 

Asynchronously sets current tunnel position mode.


The documentation for this class was generated from the following file: