PositionContext
Objective-C
@interface PositionContext : NSObject
Swift
class PositionContext : NSObject
This class handles the gps position.
-
Init with the data source context.
Declaration
Objective-C
- (nonnull instancetype)initWithContext:(nonnull DataSourceContext *)context;
Swift
init(context: DataSourceContext)
-
The delegate for the navigation contex.
Declaration
Objective-C
@property (nonatomic, weak) NSObject<PositionContextDelegate> *_Nullable delegate;
Swift
weak var delegate: (any PositionContextDelegate)? { get set }
-
Starts the generation of updates that report the user’s current position.
Declaration
Objective-C
- (void)startUpdatingPositionDelegate:(PositionType)type;
Swift
func startUpdatingPositionDelegate(_ type: PositionType)
-
Stops the generation of position updates.
Declaration
Objective-C
- (void)stopUpdatingPositionDelegate;
Swift
func stopUpdatingPositionDelegate()
-
Returns the latest position.
Declaration
Objective-C
- (nullable PositionObject *)getPosition;
Swift
func getPosition() -> PositionObject?
-
Returns the latest position.
Declaration
Objective-C
- (nullable PositionObject *)getPosition:(PositionType)type;
Swift
func getPosition(_ type: PositionType) -> PositionObject?
-
Returns the position data source type.
Declaration
Objective-C
- (PositionDataType)getSourceType;
Swift
func getSourceType() -> PositionDataType
-
Returns the position data type.
Declaration
Objective-C
- (PositionDataType)getPositionDataType;
Swift
func getPositionDataType() -> PositionDataType
-
Set the speed multiplier.
Declaration
Objective-C
- (void)setSpeedMultiplier:(float)value;
Swift
func setSpeedMultiplier(_ value: Float)
-
Clean operation.
Declaration
Objective-C
- (BOOL)clean;
Swift
func clean() -> Bool