PTAnalyticsHandler

@protocol PTAnalyticsHandler <NSObject>

Classes conforming to the PTAnalyticsHandler protocol receive analytics events when registered with a PTAnalyticsManager instance.

  • Call in catch blocks so that the analytics handler can log exceptions.

    Declaration

    Objective-C

    - (BOOL)logException:(nonnull NSException *)exception
           withExtraData:(nullable NSDictionary<id, id> *)extraData;

    Swift

    optional func logException(_ exception: NSException, withExtraData extraData: [AnyHashable : Any]?) -> Bool
  • Call to send custom events with the analytics handler.

    Declaration

    Objective-C

    - (BOOL)sendCustomEventWithTag:(nonnull NSString *)tag;

    Swift

    optional func sendCustomEvent(withTag tag: String) -> Bool