Class EpisodeDTO.Builder
- java.lang.Object
-
- com.github.m0nk3y2k4.thetvdb.internal.api.impl.model.data.EpisodeDTO.Builder
-
- Enclosing class:
- EpisodeDTO
public static class EpisodeDTO.Builder extends Object
Builder used to create a new immutableEpisodeDTO
implementation
This builder provides a fluent API for setting certain object properties and creating a new immutableEpisodeDTO
instance based on these properties. New builders may be initialized with some existing DTO instance, which presets the builders properties to the values of the given DTO, still retaining the option to make additional changes before actually building a new immutable object.
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description EpisodeDTO.Builder
absoluteNumber(Long absoluteNumber)
Initializes the value for theabsoluteNumber
attribute.EpisodeDTO.Builder
addAllDirectors(Iterable<String> elements)
Adds elements todirectors
list.EpisodeDTO.Builder
addAllGuestStars(Iterable<String> elements)
Adds elements toguestStars
list.EpisodeDTO.Builder
addAllWriters(Iterable<String> elements)
Adds elements towriters
list.EpisodeDTO.Builder
addDirectors(String element)
Adds one element todirectors
list.EpisodeDTO.Builder
addDirectors(String... elements)
Adds elements todirectors
list.EpisodeDTO.Builder
addGuestStars(String element)
Adds one element toguestStars
list.EpisodeDTO.Builder
addGuestStars(String... elements)
Adds elements toguestStars
list.EpisodeDTO.Builder
addWriters(String element)
Adds one element towriters
list.EpisodeDTO.Builder
addWriters(String... elements)
Adds elements towriters
list.EpisodeDTO.Builder
airedEpisodeNumber(Long airedEpisodeNumber)
Initializes the value for theairedEpisodeNumber
attribute.EpisodeDTO.Builder
airedSeason(Long airedSeason)
Initializes the value for theairedSeason
attribute.EpisodeDTO.Builder
airsAfterSeason(Long airsAfterSeason)
Initializes the value for theairsAfterSeason
attribute.EpisodeDTO.Builder
airsBeforeEpisode(Long airsBeforeEpisode)
Initializes the value for theairsBeforeEpisode
attribute.EpisodeDTO.Builder
airsBeforeSeason(Long airsBeforeSeason)
Initializes the value for theairsBeforeSeason
attribute.EpisodeDTO
build()
Builds a newEpisodeDTO
.EpisodeDTO.Builder
director(String director)
Deprecated.EpisodeDTO.Builder
directors(Iterable<String> elements)
Sets or replaces all elements fordirectors
list.EpisodeDTO.Builder
dvdChapter(Long dvdChapter)
Initializes the value for thedvdChapter
attribute.EpisodeDTO.Builder
dvdDiscid(String dvdDiscid)
Initializes the value for thedvdDiscid
attribute.EpisodeDTO.Builder
dvdEpisodeNumber(Long dvdEpisodeNumber)
Initializes the value for thedvdEpisodeNumber
attribute.EpisodeDTO.Builder
dvdSeason(Long dvdSeason)
Initializes the value for thedvdSeason
attribute.EpisodeDTO.Builder
episodeName(String episodeName)
Initializes the value for theepisodeName
attribute.EpisodeDTO.Builder
filename(String filename)
Initializes the value for thefilename
attribute.EpisodeDTO.Builder
firstAired(String firstAired)
Initializes the value for thefirstAired
attribute.EpisodeDTO.Builder
from(Episode instance)
Fill a builder with attribute values from the providedcom.github.m0nk3y2k4.thetvdb.api.model.data.Episode
instance.EpisodeDTO.Builder
from(EpisodeDTO instance)
Fill a builder with attribute values from the providedcom.github.m0nk3y2k4.thetvdb.internal.api.impl.model.data.EpisodeDTO
instance.EpisodeDTO.Builder
guestStars(Iterable<String> elements)
Sets or replaces all elements forguestStars
list.EpisodeDTO.Builder
id(Long id)
Initializes the value for theid
attribute.EpisodeDTO.Builder
imdbId(String imdbId)
Initializes the value for theimdbId
attribute.EpisodeDTO.Builder
lastUpdated(Long lastUpdated)
Initializes the value for thelastUpdated
attribute.EpisodeDTO.Builder
lastUpdatedBy(String lastUpdatedBy)
Initializes the value for thelastUpdatedBy
attribute.EpisodeDTO.Builder
overview(String overview)
Initializes the value for theoverview
attribute.EpisodeDTO.Builder
productionCode(String productionCode)
Initializes the value for theproductionCode
attribute.EpisodeDTO.Builder
seriesId(String seriesId)
Initializes the value for theseriesId
attribute.EpisodeDTO.Builder
showUrl(String showUrl)
Initializes the value for theshowUrl
attribute.EpisodeDTO.Builder
siteRating(Double siteRating)
Initializes the value for thesiteRating
attribute.EpisodeDTO.Builder
siteRatingCount(Long siteRatingCount)
Initializes the value for thesiteRatingCount
attribute.EpisodeDTO.Builder
thumbAdded(String thumbAdded)
Initializes the value for thethumbAdded
attribute.EpisodeDTO.Builder
thumbAuthor(Long thumbAuthor)
Initializes the value for thethumbAuthor
attribute.EpisodeDTO.Builder
thumbHeight(String thumbHeight)
Initializes the value for thethumbHeight
attribute.EpisodeDTO.Builder
thumbWidth(String thumbWidth)
Initializes the value for thethumbWidth
attribute.EpisodeDTO.Builder
writers(Iterable<String> elements)
Sets or replaces all elements forwriters
list.
-
-
-
Method Detail
-
from
public final EpisodeDTO.Builder from(Episode instance)
Fill a builder with attribute values from the providedcom.github.m0nk3y2k4.thetvdb.api.model.data.Episode
instance.- Parameters:
instance
- The instance from which to copy values- Returns:
this
builder for use in a chained invocation
-
from
public final EpisodeDTO.Builder from(EpisodeDTO instance)
Fill a builder with attribute values from the providedcom.github.m0nk3y2k4.thetvdb.internal.api.impl.model.data.EpisodeDTO
instance.- Parameters:
instance
- The instance from which to copy values- Returns:
this
builder for use in a chained invocation
-
absoluteNumber
public final EpisodeDTO.Builder absoluteNumber(@Nullable Long absoluteNumber)
Initializes the value for theabsoluteNumber
attribute.- Parameters:
absoluteNumber
- The value for absoluteNumber (can benull
)- Returns:
this
builder for use in a chained invocation
-
airedEpisodeNumber
public final EpisodeDTO.Builder airedEpisodeNumber(@Nullable Long airedEpisodeNumber)
Initializes the value for theairedEpisodeNumber
attribute.- Parameters:
airedEpisodeNumber
- The value for airedEpisodeNumber (can benull
)- Returns:
this
builder for use in a chained invocation
-
airedSeason
public final EpisodeDTO.Builder airedSeason(@Nullable Long airedSeason)
Initializes the value for theairedSeason
attribute.- Parameters:
airedSeason
- The value for airedSeason (can benull
)- Returns:
this
builder for use in a chained invocation
-
airsAfterSeason
public final EpisodeDTO.Builder airsAfterSeason(@Nullable Long airsAfterSeason)
Initializes the value for theairsAfterSeason
attribute.- Parameters:
airsAfterSeason
- The value for airsAfterSeason (can benull
)- Returns:
this
builder for use in a chained invocation
-
airsBeforeEpisode
public final EpisodeDTO.Builder airsBeforeEpisode(@Nullable Long airsBeforeEpisode)
Initializes the value for theairsBeforeEpisode
attribute.- Parameters:
airsBeforeEpisode
- The value for airsBeforeEpisode (can benull
)- Returns:
this
builder for use in a chained invocation
-
airsBeforeSeason
public final EpisodeDTO.Builder airsBeforeSeason(@Nullable Long airsBeforeSeason)
Initializes the value for theairsBeforeSeason
attribute.- Parameters:
airsBeforeSeason
- The value for airsBeforeSeason (can benull
)- Returns:
this
builder for use in a chained invocation
-
director
@Deprecated public final EpisodeDTO.Builder director(@Nullable String director)
Deprecated.Initializes the value for thedirector
attribute.- Parameters:
director
- The value for director (can benull
)- Returns:
this
builder for use in a chained invocation
-
addDirectors
public final EpisodeDTO.Builder addDirectors(String element)
Adds one element todirectors
list.- Parameters:
element
- A directors element- Returns:
this
builder for use in a chained invocation
-
addDirectors
public final EpisodeDTO.Builder addDirectors(String... elements)
Adds elements todirectors
list.- Parameters:
elements
- An array of directors elements- Returns:
this
builder for use in a chained invocation
-
directors
public final EpisodeDTO.Builder directors(Iterable<String> elements)
Sets or replaces all elements fordirectors
list.- Parameters:
elements
- An iterable of directors elements- Returns:
this
builder for use in a chained invocation
-
addAllDirectors
public final EpisodeDTO.Builder addAllDirectors(Iterable<String> elements)
Adds elements todirectors
list.- Parameters:
elements
- An iterable of directors elements- Returns:
this
builder for use in a chained invocation
-
dvdChapter
public final EpisodeDTO.Builder dvdChapter(@Nullable Long dvdChapter)
Initializes the value for thedvdChapter
attribute.- Parameters:
dvdChapter
- The value for dvdChapter (can benull
)- Returns:
this
builder for use in a chained invocation
-
dvdDiscid
public final EpisodeDTO.Builder dvdDiscid(@Nullable String dvdDiscid)
Initializes the value for thedvdDiscid
attribute.- Parameters:
dvdDiscid
- The value for dvdDiscid (can benull
)- Returns:
this
builder for use in a chained invocation
-
dvdEpisodeNumber
public final EpisodeDTO.Builder dvdEpisodeNumber(@Nullable Long dvdEpisodeNumber)
Initializes the value for thedvdEpisodeNumber
attribute.- Parameters:
dvdEpisodeNumber
- The value for dvdEpisodeNumber (can benull
)- Returns:
this
builder for use in a chained invocation
-
dvdSeason
public final EpisodeDTO.Builder dvdSeason(@Nullable Long dvdSeason)
Initializes the value for thedvdSeason
attribute.- Parameters:
dvdSeason
- The value for dvdSeason (can benull
)- Returns:
this
builder for use in a chained invocation
-
episodeName
public final EpisodeDTO.Builder episodeName(@Nullable String episodeName)
Initializes the value for theepisodeName
attribute.- Parameters:
episodeName
- The value for episodeName (can benull
)- Returns:
this
builder for use in a chained invocation
-
filename
public final EpisodeDTO.Builder filename(@Nullable String filename)
Initializes the value for thefilename
attribute.- Parameters:
filename
- The value for filename (can benull
)- Returns:
this
builder for use in a chained invocation
-
firstAired
public final EpisodeDTO.Builder firstAired(@Nullable String firstAired)
Initializes the value for thefirstAired
attribute.- Parameters:
firstAired
- The value for firstAired (can benull
)- Returns:
this
builder for use in a chained invocation
-
addGuestStars
public final EpisodeDTO.Builder addGuestStars(String element)
Adds one element toguestStars
list.- Parameters:
element
- A guestStars element- Returns:
this
builder for use in a chained invocation
-
addGuestStars
public final EpisodeDTO.Builder addGuestStars(String... elements)
Adds elements toguestStars
list.- Parameters:
elements
- An array of guestStars elements- Returns:
this
builder for use in a chained invocation
-
guestStars
public final EpisodeDTO.Builder guestStars(Iterable<String> elements)
Sets or replaces all elements forguestStars
list.- Parameters:
elements
- An iterable of guestStars elements- Returns:
this
builder for use in a chained invocation
-
addAllGuestStars
public final EpisodeDTO.Builder addAllGuestStars(Iterable<String> elements)
Adds elements toguestStars
list.- Parameters:
elements
- An iterable of guestStars elements- Returns:
this
builder for use in a chained invocation
-
id
public final EpisodeDTO.Builder id(@Nullable Long id)
Initializes the value for theid
attribute.- Parameters:
id
- The value for id (can benull
)- Returns:
this
builder for use in a chained invocation
-
imdbId
public final EpisodeDTO.Builder imdbId(@Nullable String imdbId)
Initializes the value for theimdbId
attribute.- Parameters:
imdbId
- The value for imdbId (can benull
)- Returns:
this
builder for use in a chained invocation
-
lastUpdated
public final EpisodeDTO.Builder lastUpdated(@Nullable Long lastUpdated)
Initializes the value for thelastUpdated
attribute.- Parameters:
lastUpdated
- The value for lastUpdated (can benull
)- Returns:
this
builder for use in a chained invocation
-
lastUpdatedBy
public final EpisodeDTO.Builder lastUpdatedBy(@Nullable String lastUpdatedBy)
Initializes the value for thelastUpdatedBy
attribute.- Parameters:
lastUpdatedBy
- The value for lastUpdatedBy (can benull
)- Returns:
this
builder for use in a chained invocation
-
overview
public final EpisodeDTO.Builder overview(@Nullable String overview)
Initializes the value for theoverview
attribute.- Parameters:
overview
- The value for overview (can benull
)- Returns:
this
builder for use in a chained invocation
-
productionCode
public final EpisodeDTO.Builder productionCode(@Nullable String productionCode)
Initializes the value for theproductionCode
attribute.- Parameters:
productionCode
- The value for productionCode (can benull
)- Returns:
this
builder for use in a chained invocation
-
seriesId
public final EpisodeDTO.Builder seriesId(@Nullable String seriesId)
Initializes the value for theseriesId
attribute.- Parameters:
seriesId
- The value for seriesId (can benull
)- Returns:
this
builder for use in a chained invocation
-
showUrl
public final EpisodeDTO.Builder showUrl(@Nullable String showUrl)
Initializes the value for theshowUrl
attribute.- Parameters:
showUrl
- The value for showUrl (can benull
)- Returns:
this
builder for use in a chained invocation
-
siteRating
public final EpisodeDTO.Builder siteRating(@Nullable Double siteRating)
Initializes the value for thesiteRating
attribute.- Parameters:
siteRating
- The value for siteRating (can benull
)- Returns:
this
builder for use in a chained invocation
-
siteRatingCount
public final EpisodeDTO.Builder siteRatingCount(@Nullable Long siteRatingCount)
Initializes the value for thesiteRatingCount
attribute.- Parameters:
siteRatingCount
- The value for siteRatingCount (can benull
)- Returns:
this
builder for use in a chained invocation
-
thumbAdded
public final EpisodeDTO.Builder thumbAdded(@Nullable String thumbAdded)
Initializes the value for thethumbAdded
attribute.- Parameters:
thumbAdded
- The value for thumbAdded (can benull
)- Returns:
this
builder for use in a chained invocation
-
thumbAuthor
public final EpisodeDTO.Builder thumbAuthor(@Nullable Long thumbAuthor)
Initializes the value for thethumbAuthor
attribute.- Parameters:
thumbAuthor
- The value for thumbAuthor (can benull
)- Returns:
this
builder for use in a chained invocation
-
thumbHeight
public final EpisodeDTO.Builder thumbHeight(@Nullable String thumbHeight)
Initializes the value for thethumbHeight
attribute.- Parameters:
thumbHeight
- The value for thumbHeight (can benull
)- Returns:
this
builder for use in a chained invocation
-
thumbWidth
public final EpisodeDTO.Builder thumbWidth(@Nullable String thumbWidth)
Initializes the value for thethumbWidth
attribute.- Parameters:
thumbWidth
- The value for thumbWidth (can benull
)- Returns:
this
builder for use in a chained invocation
-
addWriters
public final EpisodeDTO.Builder addWriters(String element)
Adds one element towriters
list.- Parameters:
element
- A writers element- Returns:
this
builder for use in a chained invocation
-
addWriters
public final EpisodeDTO.Builder addWriters(String... elements)
Adds elements towriters
list.- Parameters:
elements
- An array of writers elements- Returns:
this
builder for use in a chained invocation
-
writers
public final EpisodeDTO.Builder writers(Iterable<String> elements)
Sets or replaces all elements forwriters
list.- Parameters:
elements
- An iterable of writers elements- Returns:
this
builder for use in a chained invocation
-
addAllWriters
public final EpisodeDTO.Builder addAllWriters(Iterable<String> elements)
Adds elements towriters
list.- Parameters:
elements
- An iterable of writers elements- Returns:
this
builder for use in a chained invocation
-
build
public EpisodeDTO build()
Builds a newEpisodeDTO
.- Returns:
- An immutable instance of EpisodeDTO
- Throws:
IllegalStateException
- if any required attributes are missing
-
-