Warning

This feature is available in the Full MapKit SDK version

MMKAdjustedClock

class MMKAdjustedClock : NSObject

Undocumented

Summary

Instance methods

func now() -> Date
This method returns the time that has been synchronized with Mappable servers

func resume()
Notifies AdjustedClock when the application resumes the foreground state

func pause()
Notifies AdjustedClock when the application pauses and goes to the background

Properties

var isValid: Bool { get }
Tells if this object is valid or no

Instance methods

now()

func now() -> Date

This method returns the time that has been synchronized with Mappable servers. Use it if you don't trust the time on the local device because the user could have set it incorrectly. If time synchronization has failed or not yet finished, the returned value equals the local device's time.

Returns

POSIX time. For more information, see
https://en.wikipedia.org/wiki/Unix_time.


resume()

func resume()

Notifies AdjustedClock when the application resumes the foreground state.


pause()

func pause()

Notifies AdjustedClock when the application pauses and goes to the background.


Properties

isValid

var isValid: Bool { get }

Tells if this object is valid or no. Any method called on an invalid object will throw an exception. The object becomes invalid only on UI thread, and only when its implementation depends on objects already destroyed by now. Please refer to general docs about the interface for details on its invalidation.