CLSReport

@interface CLSReport : NSObject

The CLSReport exposes an interface to the phsyical report that Crashlytics has created. You can use this class to get information about the event, and can also set some values after the event has occurred.

  • Returns the session identifier for the report.

    Declaration

    Swift

    var identifier: String { get }

    Objective-C

    @property (readonly, copy, nonatomic) NSString *_Nonnull identifier;
  • Returns the custom key value data for the report.

    Declaration

    Swift

    var customKeys: [AnyHashable : Any] { get }

    Objective-C

    @property (readonly, copy, nonatomic) NSDictionary *_Nonnull customKeys;
  • Returns the CFBundleVersion of the application that generated the report.

    Declaration

    Swift

    var bundleVersion: String { get }

    Objective-C

    @property (readonly, copy, nonatomic) NSString *_Nonnull bundleVersion;
  • Returns the CFBundleShortVersionString of the application that generated the report.

    Declaration

    Swift

    var bundleShortVersionString: String { get }

    Objective-C

    @property (readonly, copy, nonatomic)
        NSString *_Nonnull bundleShortVersionString;
  • Returns the date that the report was created.

    Declaration

    Swift

    var dateCreated: Date { get }

    Objective-C

    @property (readonly, copy, nonatomic) NSDate *_Nonnull dateCreated;
  • Returns the os version that the application crashed on.

    Declaration

    Swift

    var osVersion: String { get }

    Objective-C

    @property (readonly, copy, nonatomic) NSString *_Nonnull OSVersion;
  • Returns the os build version that the application crashed on.

    Declaration

    Swift

    var osBuildVersion: String { get }

    Objective-C

    @property (readonly, copy, nonatomic) NSString *_Nonnull OSBuildVersion;
  • Returns YES if the report contains any crash information, otherwise returns NO.

    Declaration

    Swift

    var isCrash: Bool { get }

    Objective-C

    @property (readonly, assign, nonatomic) BOOL isCrash;
  • You can use this method to set, after the event, additional custom keys. The rules and semantics for this method are the same as those documented in Crashlytics.h. Be aware that the maximum size and count of custom keys is still enforced, and you can overwrite keys and/or cause excess keys to be deleted by using this method.

    Declaration

    Swift

    func setObjectValue(_ value: Any?, forKey key: String)

    Objective-C

    - (void)setObjectValue:(nullable id)value forKey:(nonnull NSString *)key;
  • Record an application-specific user identifier. See Crashlytics.h for details.

    Declaration

    Swift

    var userIdentifier: String? { get set }

    Objective-C

    @property (readwrite, copy, nonatomic, nullable) NSString *userIdentifier;
  • Record a user name. See Crashlytics.h for details.

    Declaration

    Swift

    var userName: String? { get set }

    Objective-C

    @property (readwrite, copy, nonatomic, nullable) NSString *userName;
  • Record a user email. See Crashlytics.h for details.

    Declaration

    Swift

    var userEmail: String? { get set }

    Objective-C

    @property (readwrite, copy, nonatomic, nullable) NSString *userEmail;