WatchNextProgram.Builder


public final class WatchNextProgram.Builder


This Builder class simplifies the creation of a WatchNextProgram object.

Summary

Public constructors

Creates a new Builder object.

Creates a new Builder object with values copied from another Program.

Public methods

WatchNextProgram
WatchNextProgram.Builder
setLastEngagementTimeUtcMillis(long lastEngagementTimeUtcMillis)

Sets the time when the program is going to begin in milliseconds since the epoch.

WatchNextProgram.Builder
setWatchNextType(int watchNextType)

Sets the "watch next" type of this program content.

Public constructors

Builder

Added in 1.1.0-alpha02
public Builder()

Creates a new Builder object.

Builder

Added in 1.1.0-alpha02
public Builder(WatchNextProgram other)

Creates a new Builder object with values copied from another Program.

Parameters
WatchNextProgram other

The Program you're copying from.

Public methods

build

Added in 1.1.0-alpha02
public WatchNextProgram build()
Returns
WatchNextProgram

A new Program with values supplied by the Builder.

setLastEngagementTimeUtcMillis

Added in 1.1.0-alpha02
public WatchNextProgram.Builder setLastEngagementTimeUtcMillis(long lastEngagementTimeUtcMillis)

Sets the time when the program is going to begin in milliseconds since the epoch.

Parameters
long lastEngagementTimeUtcMillis

The value of COLUMN_LAST_ENGAGEMENT_TIME_UTC_MILLIS for the program.

Returns
WatchNextProgram.Builder

This Builder object to allow for chaining of calls to builder methods.

setWatchNextType

Added in 1.1.0-alpha02
public WatchNextProgram.Builder setWatchNextType(int watchNextType)

Sets the "watch next" type of this program content.

The value should match one of the followings: WATCH_NEXT_TYPE_CONTINUE, WATCH_NEXT_TYPE_NEXT, and WATCH_NEXT_TYPE_NEW.

Parameters
int watchNextType

The value of COLUMN_WATCH_NEXT_TYPE for the program.

Returns
WatchNextProgram.Builder

This Builder object to allow for chaining of calls to builder methods.