SWRLContent Class Reference
Inherits from | NSObject |
---|---|
Declared in | SWRLContent.h SWRLContent.m |
Overview
Each SWRLContent object represents a unique impression. A SWRLContent object encapsulates information about content that was received for a given visit in response to a content request made by the SWRLContentManager. Content requests are made in response to visit events like starting a visit and updating dwell time for a visit. For content that requires a dwell trigger, the server will push back that information to the client and the client will automatically delay making further content requests until the dwell triggers have been reached.
Accessing Attributes
identifier
The unique identifier (UUID) for this impression.
@property (nonatomic, readonly) NSString *identifier
Declared In
SWRLContent.h
content
This NSDictionary is a representation of the raw JSON content response.
@property (nonatomic, readonly) NSDictionary *content
Declared In
SWRLContent.h
type
The content type whose value will be one of SWRLContentType.
@property (nonatomic, readonly) SWRLContentType type
Declared In
SWRLContent.h
customType
The identifying string associated with a custom type or nil
@property (nonatomic, readonly) NSString *customType
Declared In
SWRLContent.h
received
The epoch (1/1/70) timestamp that represents when this content was originally received.
@property (nonatomic, readonly) NSTimeInterval received
Declared In
SWRLContent.h
fromNotification
Content was received through an notification launch
@property (nonatomic, readonly) BOOL fromNotification
Declared In
SWRLContent.h
fromAPS
Content was received through a schedule push campaign
@property (nonatomic, readonly) BOOL fromAPS
Declared In
SWRLContent.h
notification
The notification associated with this content. You can access this field at any time to get a copy of the notification that was sent or would be sent. Accessing this property does not cause any notifications to be sent.
@property (nonatomic, readonly) id notification
Discussion
Notification are created with a userInfo dictionary that is: `@{ @“com.swirl” : @{ SWRLNotificationContentKey: self.content }}; which enables a SWRLContent object to be recreated from a notification.
Declared In
SWRLContent.h
url
The URL associated with this content. For SWRLContentTypeURL this is the deep link URL, For SWRLContentTypeSwirl this is a URL representing a call to format an HTML impression.
@property (nonatomic, nullable, readonly) NSURL *url
Declared In
SWRLContent.h
attributes
This dictionary contains any custom attributes associated with this creative as created and assigned using the platform.
@property (nonatomic, nullable, readonly) NSDictionary *attributes
Declared In
SWRLContent.h
thumbnail
This is a thumbnail created of the creative. This is only available if the creative has ever been rendered on the screen.
@property (nonatomic, nullable, readonly) UIImage *thumbnail
Declared In
SWRLContent.h