GCKMediaInformationBuilder Class

GCKMediaInformationBuilder Class Reference

Overview

A builder object for constructing new or derived GCKMediaInformation instances.

The builder may be used to derive a GCKMediaInformation from an existing one:

[[ GCKMediaInformationBuilder alloc] initWithMediaInformation:originalMediaInfo];
builder. contentID = ...; // Change the content ID.
builder. streamDuration = 100; // Change the stream duration.
GCKMediaInformation *derivedMediaInfo = [builder build ];

It can also be used to construct a new GCKMediaInformation from scratch:

[[ GCKMediaInformationBuilder alloc] initWithContentURL:...];
builder. contentType = ...;
builder. streamType = ...;
builder. metadata = ...;
// Set all other desired propreties...
GCKMediaInformation *newMediaInfo = [builder build ];
Since
4.0

Inherits NSObject.

Instance Method Summary

(instancetype) 
Constructs a new GCKMediaInformationBuilder with the given required attributes, and all other attributes initialized to default values. More...
(instancetype) 
Constructs a new GCKMediaInformationBuilder with the given required attributes, and all other attributes initialized to default values. More...
(instancetype) 
Constructs a new GCKMediaInformationBuilder with attributes copied from the given GCKMediaInformation instance. More...
(instancetype) 
Constructs a new GCKMediaInformationBuilder with the given required attributes, and all other attributes initialized to default values. More...
(instancetype) 
Constructs a new GCKMediaInformationBuilder with the given required attributes, and all other attributes initialized to default values. More...
Builds a GCKMediaInformation using the builder's current attributes. More...

Property Summary

NSString * 
The content ID for this stream. More...
NSURL * 
The URL of the content to be played. More...
The stream type. More...
NSString * 
The content (MIME) type. More...
The media item metadata. More...
NSArray< GCKAdBreakInfo * > * 
The list of ad breaks in this content. More...
NSArray< GCKAdBreakClipInfo * > * 
The list of ad break clips in this content. More...
NSTimeInterval 
The length of the stream, in seconds, or INFINITY if it is a live stream. More...
NSArray< GCKMediaTrack * > * 
The media tracks for this stream. More...
The text track style for this stream. More...
NSString * 
The deep link for the media as used by Google Assistant, if any. More...
The VMAP request configuration if any. More...
NSTimeInterval 
The start time of the stream, in seconds in epoch time, or kGCKInvalidTimeInterval if it is not available. More...
The format of the HLS audio segment. More...
The format of the HLS video segment. More...
id 
The custom data, if any. More...

Method Detail

- (instancetype) initWithContentURL: (NSURL *)  contentURL

Constructs a new GCKMediaInformationBuilder with the given required attributes, and all other attributes initialized to default values.

Parameters
contentURL
The URL of the content to be played.
Since
4.3.4
- (instancetype) initWithEntity: (NSString *)  entity

Constructs a new GCKMediaInformationBuilder with the given required attributes, and all other attributes initialized to default values.

- (instancetype) initWithMediaInformation: ( GCKMediaInformation *)  mediaInfo

Constructs a new GCKMediaInformationBuilder with attributes copied from the given GCKMediaInformation instance.

Parameters
mediaInfo
The instance to copy.
- (instancetype) initWithContentID: (NSString *)  contentID

Constructs a new GCKMediaInformationBuilder with the given required attributes, and all other attributes initialized to default values.

Deprecated:
Use initWithContentURL: or initWithEntity: instead.
- (instancetype) initWithContentID: (NSString *)  contentID
entity: (NSString *)  entity

Constructs a new GCKMediaInformationBuilder with the given required attributes, and all other attributes initialized to default values.

Deprecated:
Use initWithContentURL: or initWithEntity: instead.
- ( GCKMediaInformation *) build

Builds a GCKMediaInformation using the builder's current attributes.

Returns
The new GCKMediaInformation instance.

Property Detail

- (NSString*) contentID
read write nonatomic copy

The content ID for this stream.

Deprecated:
Use contentURL and entity instead.
- (NSURL*) contentURL
read write nonatomic copy

The URL of the content to be played.

Since
4.3.4
- ( GCKMediaStreamType ) streamType
read write nonatomic assign

The stream type.

Defaults to GCKMediaStreamTypeBuffered.

- (NSString*) contentType
read write nonatomic copy

The content (MIME) type.

- ( GCKMediaMetadata *) metadata
read write nonatomic assign

The media item metadata.

- (NSArray< GCKAdBreakInfo *>*) adBreaks
read write nonatomic copy

The list of ad breaks in this content.

- (NSArray< GCKAdBreakClipInfo *>*) adBreakClips
read write nonatomic copy

The list of ad break clips in this content.

- (NSTimeInterval) streamDuration
read write nonatomic assign

The length of the stream, in seconds, or INFINITY if it is a live stream.

Defaults to 0.

- (NSArray< GCKMediaTrack *>*) mediaTracks
read write nonatomic copy

The media tracks for this stream.

- ( GCKMediaTextTrackStyle *) textTrackStyle
read write nonatomic copy

The text track style for this stream.

- (NSString*) entity
read write nonatomic copy

The deep link for the media as used by Google Assistant, if any.

- ( GCKVASTAdsRequest *) VMAP
read write nonatomic assign

The VMAP request configuration if any.

See more here: Digital Video Ad Serving Template 4.0 . If this is non-nil, all other ads related fields will be ignored.

Since
4.3.4
- (NSTimeInterval) startAbsoluteTime
read write nonatomic assign

The start time of the stream, in seconds in epoch time, or kGCKInvalidTimeInterval if it is not available.

Defaults to kGCKInvalidTimeInterval .

Since
4.4.1
- ( GCKHLSSegmentFormat ) hlsSegmentFormat
read write nonatomic assign

The format of the HLS audio segment.

Since
4.6.0
- ( GCKHLSVideoSegmentFormat ) hlsVideoSegmentFormat
read write nonatomic assign

The format of the HLS video segment.

Since
4.6.0
- (id) customData
read write nonatomic assign

The custom data, if any.

Create a Mobile Website
View Site in Mobile | Classic
Share by: