TimeDistanceObject
Objective-C
@interface TimeDistanceObject : NSObject
Swift
class TimeDistanceObject : NSObject
This class encapsulates time distance information.
-
Initializes and returns a newly allocated object using the model data.
Declaration
Objective-C
- (nonnull instancetype)initWithModelData:(nonnull void *)data;
-
Returns the model data.
Declaration
Objective-C
- (nonnull void *)getModelData;
-
Returns the total time in seconds.
Declaration
Objective-C
- (unsigned int)getTotalTime;
Swift
func getTotalTime() -> UInt32
-
Returns the unrestricted time in seconds.
Declaration
Objective-C
- (unsigned int)getUnrestrictedTime;
Swift
func getUnrestrictedTime() -> UInt32
-
Returns the restricted time in seconds.
Declaration
Objective-C
- (unsigned int)getRestrictedTime;
Swift
func getRestrictedTime() -> UInt32
-
Returns the restricted time at beginning.
Declaration
Objective-C
- (unsigned int)getRestrictedTimeAtBegin;
Swift
func getRestrictedTimeAtBegin() -> UInt32
-
Returns the restricted time at end.
Declaration
Objective-C
- (unsigned int)getRestrictedTimeAtEnd;
Swift
func getRestrictedTimeAtEnd() -> UInt32
-
Returns the total distance in meters
Declaration
Objective-C
- (unsigned int)getTotalDistance;
Swift
func getTotalDistance() -> UInt32
-
Returns the total distance measurement. @details Measurement of total distance based on accuracy. @details >20 km: 1 km accuracy. @details 1 - 20 km: 0.1 km accuracy. @details 500 - 1,000 m: 50 m accuracy. @details 200 - 500 m: 25 m accuracy. @details 100 - 200 m: 10 m accuracy. @details 0 - 100 m: 5 m accuracy.
Declaration
Objective-C
- (nonnull NSMeasurement<NSUnitLength *> *)getTotalDistanceMeasurement;
Swift
func getTotalDistanceMeasurement() -> Measurement<UnitLength>
-
Returns the unrestricted distance in meters.
Declaration
Objective-C
- (unsigned int)getUnrestrictedDistance;
Swift
func getUnrestrictedDistance() -> UInt32
-
Returns the restricted distance in meters.
Declaration
Objective-C
- (unsigned int)getRestrictedDistance;
Swift
func getRestrictedDistance() -> UInt32
-
Returns the restricted distance at beginning in meters.
Declaration
Objective-C
- (unsigned int)getRestrictedDistanceAtBegin;
Swift
func getRestrictedDistanceAtBegin() -> UInt32
-
Returns the restricted distance at end in meters.
Declaration
Objective-C
- (unsigned int)getRestrictedDistanceAtEnd;
Swift
func getRestrictedDistanceAtEnd() -> UInt32
-
Returns the total distance formatted string.
Declaration
Objective-C
- (nonnull NSString *)getTotalDistanceFormatted;
Swift
func getTotalDistanceFormatted() -> String
-
Returns the distance unit formatted string.
Declaration
Objective-C
- (nonnull NSString *)getTotalDistanceUnitFormatted;
Swift
func getTotalDistanceUnitFormatted() -> String
-
Returns the time formatted string.
Declaration
Objective-C
- (nonnull NSString *)getTotalTimeFormatted;
Swift
func getTotalTimeFormatted() -> String
-
Returns the time unit formatted string.
Declaration
Objective-C
- (nonnull NSString *)getTotalTimeUnitFormatted;
Swift
func getTotalTimeUnitFormatted() -> String
-
Returns the formatted distance string.
Declaration
Objective-C
- (nonnull NSString *)getFormattedDistance:(int)value;
Swift
func getFormattedDistance(_ value: Int32) -> String
Parameters
value
Must be in meters. @details > 20 km - 1 km accuracy - KM @details 1 - 20 km - 0.1 km accuracy - KM @details 500 - 1,000 m - 50 m accuracy - M @details 200 - 500 m - 25 m accuracy - M @details 100 - 200 m - 10 m accuracy - M @details 0 - 100 m - 5 m accuracy - M
-
Returns the formatted distance unit string.
Declaration
Objective-C
- (nonnull NSString *)getFormattedDistanceUnit:(int)value;
Swift
func getFormattedDistanceUnit(_ value: Int32) -> String
Parameters
value
Must be in meters.