UAMediaEventTemplate

@interface UAMediaEventTemplate : NSObject

A UAMediaEventTemplate represents a custom media event template for the application.

  • The event’s ID. The ID’s length must not exceed 255 characters or it will invalidate the event.

    Declaration

    Objective-C

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

    Swift

    var identifier: String? { get set }
  • The event’s category. The category’s length must not exceed 255 characters or it will invalidate the event.

    Declaration

    Objective-C

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

    Swift

    var category: String? { get set }
  • The event’s type. The type’s length must not exceed 255 characters or it will invalidate the event.

    Declaration

    Objective-C

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

    Swift

    var type: String? { get set }
  • The event’s description. The description’s length must not exceed 255 characters or it will invalidate the event.

    Declaration

    Objective-C

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

    Swift

    var eventDescription: String? { get set }
  • YES if the event is a feature, else NO.

    Declaration

    Objective-C

    @property (assign, readwrite, nonatomic) BOOL isFeature;

    Swift

    var isFeature: Bool { get set }
  • The event’s author. The author’s length must not exceed 255 characters or it will invalidate the event.

    Declaration

    Objective-C

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

    Swift

    var author: String? { get set }
  • The event’s publishedDate. The publishedDate’s length must not exceed 255 characters or it will invalidate the event.

    Declaration

    Objective-C

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

    Swift

    var publishedDate: String? { get set }
  • Factory method for creating a browsed content event template.

    Declaration

    Objective-C

    + (nonnull instancetype)browsedTemplate;

    Swift

    class func browsed() -> Self
  • Factory method for creating a starred content event template.

    Declaration

    Objective-C

    + (nonnull instancetype)starredTemplate;

    Swift

    class func starred() -> Self
  • Factory method for creating a shared content event template.

    Declaration

    Objective-C

    + (nonnull instancetype)sharedTemplate;

    Swift

    class func shared() -> Self
  • Factory method for creating a shared content event template. If the source or medium exceeds 255 characters it will cause the event to be invalid.

    Declaration

    Objective-C

    + (nonnull instancetype)sharedTemplateWithSource:(nullable NSString *)source
                                          withMedium:(nullable NSString *)medium;

    Swift

    class func sharedTemplate(withSource source: String?, withMedium medium: String?) -> Self

    Parameters

    source

    The source as an NSString.

    medium

    The medium as an NSString.

  • Factory method for creating a consumed content event template.

    Declaration

    Objective-C

    + (nonnull instancetype)consumedTemplate;

    Swift

    class func consumed() -> Self
  • Factory method for creating a consumed content event template with a value.

    Declaration

    Objective-C

    + (nonnull instancetype)consumedTemplateWithValueFromString:
        (nullable NSString *)eventValue;

    Swift

    class func consumedTemplateWithValue(from eventValue: String?) -> Self

    Parameters

    eventValue

    The value of the event as as string. The value must be between -2^31 and 2^31 - 1 or it will invalidate the event.

  • Factory method for creating a consumed content event template with a value.

    Declaration

    Objective-C

    + (nonnull instancetype)consumedTemplateWithValue:
        (nullable NSNumber *)eventValue;

    Swift

    class func consumedTemplate(withValue eventValue: NSNumber?) -> Self

    Parameters

    eventValue

    The value of the event. The value must be between -2^31 and 2^31 - 1 or it will invalidate the event.

  • Creates the custom media event.

    Declaration

    Objective-C

    - (nonnull UACustomEvent *)createEvent;

    Swift

    func createEvent() -> UACustomEvent