GCKMediaLoadRequestDataBuilder Class

GCKMediaLoadRequestDataBuilder Class Reference

Overview

A builder object for constructing new or derived GCKMediaLoadRequestData instances.

The builder may be used to derive GCKMediaLoadRequestData from an existing one.

Since
4.4.1

Inherits NSObject.

Instance Method Summary

(instancetype) - init
 Initializes a GCKMediaLoadRequestData with default values for all properties. More...
 
(instancetype) - initWithMediaLoadRequestData:
 Initializes a GCKMediaLoadRequestData with a given GCKMediaLoadRequestData object. More...
 
(GCKMediaLoadRequestData *) - build
 Builds a GCKMediaLoadRequestData using the builder's current attributes. More...
 

Property Summary

GCKMediaInformationmediaInformation
 The media item to load. More...
 
GCKMediaQueueDataqueueData
 The metadata of media item or queue. More...
 
NSNumber * autoplay
 The flag to indicate whether playback should start immediately. More...
 
NSTimeInterval startTime
 The initial position to start playback. More...
 
float playbackRate
 The playback rate. More...
 
NSArray< NSNumber * > * activeTrackIDs
 An array of integers specifying the active tracks. More...
 
id customData
 Custom application-specific data to pass along with the request. More...
 
NSString * credentials
 The user credentials for the media item being loaded. More...
 
NSString * credentialsType
 The type of user credentials specified in GCKMediaLoadRequestData::credentials. More...
 
NSString * atvCredentials
 The alternate Android TV credentials for the media item being loaded. More...
 
NSString * atvCredentialsType
 The type of Android TV credentials specified in GCKMediaLoadRequestData::atvCredentials. More...
 

Method Detail

- (instancetype) init

Initializes a GCKMediaLoadRequestData with default values for all properties.

- (instancetype) initWithMediaLoadRequestData: (GCKMediaLoadRequestData *)  requestData

Initializes a GCKMediaLoadRequestData with a given GCKMediaLoadRequestData object.

Builds a GCKMediaLoadRequestData using the builder's current attributes.

Returns
The new GCKMediaLoadRequestData instance.

Property Detail

- (GCKMediaInformation*) mediaInformation
readwritenonatomiccopy

The media item to load.

- (GCKMediaQueueData*) queueData
readwritenonatomiccopy

The metadata of media item or queue.

- (NSNumber*) autoplay
readwritenonatomiccopy

The flag to indicate whether playback should start immediately.

The default value is @(YES). If this is nil, the property of GCKMediaQueueItem in queueData will take effect. If queueData is nil either, playback will not start immediately.

- (NSTimeInterval) startTime
readwritenonatomicassign

The initial position to start playback.

The default value is kGCKInvalidTimeInterval, which indicates a default playback position. If playing Video-On-Demand streams, it starts from 0; if playing live streams, it starts from live edge.

- (float) playbackRate
readwritenonatomicassign

The playback rate.

The default value is 1.

- (NSArray<NSNumber *>*) activeTrackIDs
readwritenonatomicstrong

An array of integers specifying the active tracks.

The default value is nil.

- (id) customData
readwritenonatomicstrong

Custom application-specific data to pass along with the request.

Must either be an object that can be serialized to JSON using NSJSONSerialization, or nil.

- (NSString*) credentials
readwritenonatomiccopy

The user credentials for the media item being loaded.

- (NSString*) credentialsType
readwritenonatomiccopy

The type of user credentials specified in GCKMediaLoadRequestData::credentials.

- (NSString*) atvCredentials
readwritenonatomiccopy

The alternate Android TV credentials for the media item being loaded.

If set, these credentials will override the value set in GCKMediaLoadRequestData::credentials if the receiver is an Android TV app. On the receiver side, these credentials can be accessed from MediaLoadRequestData#getCredentials.

Since
4.7.0
- (NSString*) atvCredentialsType
readwritenonatomiccopy

The type of Android TV credentials specified in GCKMediaLoadRequestData::atvCredentials.

If set, this credentials type will override the value set in GCKMediaLoadRequestData::credentialsType if the receiver is an Android TV app. On the receiver side, these credentials can be accessed from MediaLoadRequestData#getCredentialsType.

Since
4.7.0