ZendriveAccidentInfo
@interface ZendriveAccidentInfo : NSObject
ZendriveAccidentInfo
Wrapper for meta-information related to an accident detected by the SDK.
-
The unique Id of drive during which the accident occured
Declaration
Objective-C
@property (readonly, nonatomic, nonnull) NSString *driveId; -
The location of the accident.
Declaration
Objective-C
@property (readonly, nonatomic, nonnull) ZendriveLocationPoint *accidentLocation; -
The timestamp of the accident in milliseconds since epoch.
Declaration
Objective-C
@property (readonly, nonatomic) long long timestamp; -
The session that was in progress when the accident occured, if a session was started in the SDK.
Declaration
Objective-C
@property (readonly, nonatomic, nullable) NSString *sessionId; -
The tracking id of the ongoing drive when the accident occured.
See
+[Zendrive startManualDrive:completionHandler]Declaration
Objective-C
@property (readonly, nonatomic, nullable) NSString *trackingId; -
The confidence of detected accident.
Declaration
Objective-C
@property (readonly, nonatomic) ZendriveAccidentConfidence confidence; -
A unique identifier of this accident.
Declaration
Objective-C
@property (readonly, nonatomic, nonnull) NSString *accidentId; -
Initializer for
ZendriveAccidentInfo.Declaration
Objective-C
- (nonnull id)initWithLocation:(nonnull ZendriveLocationPoint *)location timestamp:(long long)timestamp trackingId:(nullable NSString *)trackingId sessionId:(nullable NSString *)sessionId confidence:(ZendriveAccidentConfidence)confidence accidentId:(nonnull NSString *)accidentId driveId:(nonnull NSString *)driveId;Parameters
locationThe location of the accident
timestampThe timestamp of the accident in milliseconds since epoch
trackingIdThe tracking id of the ongoing drive when the accident occured
sessionIdThe session that was in progress when the accident occured, if a session was started in the SDK
confidenceConfidence measure of the detected accident
accidentIdA unique identifier of this accident
driveIdThe unique Id of drive during which the accident occured
Return Value
ZendriveAccidentInfoobject -
Returns a dictionary that represents the
ZendriveAccidentInfoobject.Declaration
Objective-C
- (nonnull NSDictionary *)toDictionary; -
Returns a JSON formatted string that represents the
ZendriveAccidentInfoobject.Declaration
Objective-C
- (nonnull NSString *)toJson;
ZendriveAccidentInfo Class Reference