public static class

AdBreakClipInfo.Builder

extends Object
java.lang.Object
   ↳ com.google.android.gms.cast.AdBreakClipInfo.Builder

Class Overview

A builder for AdBreakClipInfo.

Summary

Public Constructors
AdBreakClipInfo.Builder(String id)
Public Methods
AdBreakClipInfo build()
AdBreakClipInfo.Builder setClickThroughUrl(String clickThroughUrl)
Sets this clip's click through URL.
AdBreakClipInfo.Builder setContentId(String contentId)
Sets this clip's content ID.
AdBreakClipInfo.Builder setContentUrl(String contentUrl)
Sets this clip's content URL.
AdBreakClipInfo.Builder setCustomDataJsonString(String customDataJsonString)
Sets this clip's custom data as a string.
AdBreakClipInfo.Builder setDurationInMs(long durationInMs)
Sets this clip's duration in milliseconds.
AdBreakClipInfo.Builder setHlsSegmentFormat(String hlsSegmentFormat)
Sets HlsSegmentFormat of the ad break clip, or empty String if not set.
AdBreakClipInfo.Builder setImageUrl(String imageUrl)
Sets this clip's image URL.
AdBreakClipInfo.Builder setMimeType(String mimeType)
Sets this clip's mime type.
AdBreakClipInfo.Builder setTitle(String title)
Sets this clip's title.
AdBreakClipInfo.Builder setWhenSkippableInMs(long whenSkippableInMs)
Sets the time in milliseconds when this break clip becomes skippable.
[Expand]
Inherited Methods
From class java.lang.Object

Public Constructors

public AdBreakClipInfo.Builder (String id)

Construct a AdBreakClipInfo.Builder.

Parameters
id String: The ad clip's ID, referenced by AdBreakInfo

Public Methods

public AdBreakClipInfo build ()

Returns
AdBreakClipInfo

public AdBreakClipInfo.Builder setClickThroughUrl (String clickThroughUrl)

Sets this clip's click through URL.

Parameters
clickThroughUrl String
Returns
AdBreakClipInfo.Builder

public AdBreakClipInfo.Builder setContentId (String contentId)

Sets this clip's content ID. Typically the URL of the break clip (playing on the receiver).

Parameters
contentId String
Returns
AdBreakClipInfo.Builder

public AdBreakClipInfo.Builder setContentUrl (String contentUrl)

Sets this clip's content URL. If contentUrl is provided, the receiver will use it as the content's URL, otherwise contentId will be used to load the clip on the receiver.

Parameters
contentUrl String
Returns
AdBreakClipInfo.Builder

public AdBreakClipInfo.Builder setCustomDataJsonString (String customDataJsonString)

Sets this clip's custom data as a string.

Parameters
customDataJsonString String
Returns
AdBreakClipInfo.Builder

public AdBreakClipInfo.Builder setDurationInMs (long durationInMs)

Sets this clip's duration in milliseconds.

Parameters
durationInMs long
Returns
AdBreakClipInfo.Builder

public AdBreakClipInfo.Builder setHlsSegmentFormat (String hlsSegmentFormat)

Sets HlsSegmentFormat of the ad break clip, or empty String if not set.

Parameters
hlsSegmentFormat String
Returns
AdBreakClipInfo.Builder

public AdBreakClipInfo.Builder setImageUrl (String imageUrl)

Sets this clip's image URL.

Parameters
imageUrl String
Returns
AdBreakClipInfo.Builder

public AdBreakClipInfo.Builder setMimeType (String mimeType)

Sets this clip's mime type.

Parameters
mimeType String
Returns
AdBreakClipInfo.Builder

public AdBreakClipInfo.Builder setTitle (String title)

Sets this clip's title.

Parameters
title String
Returns
AdBreakClipInfo.Builder

public AdBreakClipInfo.Builder setWhenSkippableInMs (long whenSkippableInMs)

Sets the time in milliseconds when this break clip becomes skippable. a value of 5000 means that end user can skip this break clip after 5 seconds. A value of AD_BREAK_CLIP_NOT_SKIPPABLE means that current break clip is not skippable.

Parameters
whenSkippableInMs long
Returns
AdBreakClipInfo.Builder