public final class

PreviewProgram.Builder

extends BasePreviewProgram.Builder<PreviewProgram.Builder>

 java.lang.Object

androidx.tvprovider.media.tv.BaseProgram.Builder<BasePreviewProgram.Builder>

androidx.tvprovider.media.tv.BasePreviewProgram.Builder<PreviewProgram.Builder>

↳androidx.tvprovider.media.tv.PreviewProgram.Builder

Overview

This Builder class simplifies the creation of a PreviewProgram object.

Summary

Fields
from BaseProgram.Builder<T>mValues
Constructors
publicBuilder()

Creates a new Builder object.

publicBuilder(PreviewProgram other)

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

Methods
public PreviewProgrambuild()

public PreviewProgram.BuildersetChannelId(long channelId)

Sets the ID of the Channel that contains this program.

public PreviewProgram.BuildersetWeight(int weight)

Sets the weight of the preview program within the channel.

from BasePreviewProgram.Builder<T>setAuthor, setAvailability, setBrowsable, setContentId, setDurationMillis, setEndTimeUtcMillis, setGenre, setIntent, setIntentUri, setInteractionCount, setInteractionType, setInternalProviderId, setItemCount, setLastPlaybackPositionMillis, setLive, setLogoContentDescription, setLogoUri, setOfferPrice, setPosterArtAspectRatio, setPreviewAudioUri, setPreviewVideoUri, setReleaseDate, setReleaseDate, setStartingPrice, setStartTimeUtcMillis, setThumbnailAspectRatio, setTransient, setTvSeriesItemType, setType
from BaseProgram.Builder<T>setAudioLanguages, setCanonicalGenres, setContentRatings, setDescription, setEpisodeNumber, setEpisodeNumber, setEpisodeTitle, setId, setInternalProviderData, setInternalProviderFlag1, setInternalProviderFlag2, setInternalProviderFlag3, setInternalProviderFlag4, setLongDescription, setPackageName, setPosterArtUri, setReviewRating, setReviewRatingStyle, setSearchable, setSeasonNumber, setSeasonNumber, setSeasonTitle, setSeriesId, setThumbnailUri, setTitle, setVideoHeight, setVideoWidth
from java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructors

public Builder()

Creates a new Builder object.

public Builder(PreviewProgram other)

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

Parameters:

other: The Program you're copying from.

Methods

public PreviewProgram.Builder setChannelId(long channelId)

Sets the ID of the Channel that contains this program.

Parameters:

channelId: The value of {@link PreviewPrograms#COLUMN_CHANNEL_ID for the program.

Returns:

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

public PreviewProgram.Builder setWeight(int weight)

Sets the weight of the preview program within the channel.

Parameters:

weight: The value of TvContractCompat.PreviewPrograms.COLUMN_WEIGHT for the program.

Returns:

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

public PreviewProgram build()

Returns:

A new Program with values supplied by the Builder.