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 immutableEpisodeDTOimplementation
This builder provides a fluent API for setting certain object properties and creating a new immutableEpisodeDTOinstance 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.BuilderabsoluteNumber(Long absoluteNumber)Initializes the value for theabsoluteNumberattribute.EpisodeDTO.BuilderaddAllDirectors(Iterable<String> elements)Adds elements todirectorslist.EpisodeDTO.BuilderaddAllGuestStars(Iterable<String> elements)Adds elements toguestStarslist.EpisodeDTO.BuilderaddAllWriters(Iterable<String> elements)Adds elements towriterslist.EpisodeDTO.BuilderaddDirectors(String element)Adds one element todirectorslist.EpisodeDTO.BuilderaddDirectors(String... elements)Adds elements todirectorslist.EpisodeDTO.BuilderaddGuestStars(String element)Adds one element toguestStarslist.EpisodeDTO.BuilderaddGuestStars(String... elements)Adds elements toguestStarslist.EpisodeDTO.BuilderaddWriters(String element)Adds one element towriterslist.EpisodeDTO.BuilderaddWriters(String... elements)Adds elements towriterslist.EpisodeDTO.BuilderairedEpisodeNumber(Long airedEpisodeNumber)Initializes the value for theairedEpisodeNumberattribute.EpisodeDTO.BuilderairedSeason(Long airedSeason)Initializes the value for theairedSeasonattribute.EpisodeDTO.BuilderairsAfterSeason(Long airsAfterSeason)Initializes the value for theairsAfterSeasonattribute.EpisodeDTO.BuilderairsBeforeEpisode(Long airsBeforeEpisode)Initializes the value for theairsBeforeEpisodeattribute.EpisodeDTO.BuilderairsBeforeSeason(Long airsBeforeSeason)Initializes the value for theairsBeforeSeasonattribute.EpisodeDTObuild()Builds a newEpisodeDTO.EpisodeDTO.Builderdirector(String director)Deprecated.EpisodeDTO.Builderdirectors(Iterable<String> elements)Sets or replaces all elements fordirectorslist.EpisodeDTO.BuilderdvdChapter(Long dvdChapter)Initializes the value for thedvdChapterattribute.EpisodeDTO.BuilderdvdDiscid(String dvdDiscid)Initializes the value for thedvdDiscidattribute.EpisodeDTO.BuilderdvdEpisodeNumber(Long dvdEpisodeNumber)Initializes the value for thedvdEpisodeNumberattribute.EpisodeDTO.BuilderdvdSeason(Long dvdSeason)Initializes the value for thedvdSeasonattribute.EpisodeDTO.BuilderepisodeName(String episodeName)Initializes the value for theepisodeNameattribute.EpisodeDTO.Builderfilename(String filename)Initializes the value for thefilenameattribute.EpisodeDTO.BuilderfirstAired(String firstAired)Initializes the value for thefirstAiredattribute.EpisodeDTO.Builderfrom(Episode instance)Fill a builder with attribute values from the providedcom.github.m0nk3y2k4.thetvdb.api.model.data.Episodeinstance.EpisodeDTO.Builderfrom(EpisodeDTO instance)Fill a builder with attribute values from the providedcom.github.m0nk3y2k4.thetvdb.internal.api.impl.model.data.EpisodeDTOinstance.EpisodeDTO.BuilderguestStars(Iterable<String> elements)Sets or replaces all elements forguestStarslist.EpisodeDTO.Builderid(Long id)Initializes the value for theidattribute.EpisodeDTO.BuilderimdbId(String imdbId)Initializes the value for theimdbIdattribute.EpisodeDTO.BuilderlastUpdated(Long lastUpdated)Initializes the value for thelastUpdatedattribute.EpisodeDTO.BuilderlastUpdatedBy(String lastUpdatedBy)Initializes the value for thelastUpdatedByattribute.EpisodeDTO.Builderoverview(String overview)Initializes the value for theoverviewattribute.EpisodeDTO.BuilderproductionCode(String productionCode)Initializes the value for theproductionCodeattribute.EpisodeDTO.BuilderseriesId(String seriesId)Initializes the value for theseriesIdattribute.EpisodeDTO.BuildershowUrl(String showUrl)Initializes the value for theshowUrlattribute.EpisodeDTO.BuildersiteRating(Double siteRating)Initializes the value for thesiteRatingattribute.EpisodeDTO.BuildersiteRatingCount(Long siteRatingCount)Initializes the value for thesiteRatingCountattribute.EpisodeDTO.BuilderthumbAdded(String thumbAdded)Initializes the value for thethumbAddedattribute.EpisodeDTO.BuilderthumbAuthor(Long thumbAuthor)Initializes the value for thethumbAuthorattribute.EpisodeDTO.BuilderthumbHeight(String thumbHeight)Initializes the value for thethumbHeightattribute.EpisodeDTO.BuilderthumbWidth(String thumbWidth)Initializes the value for thethumbWidthattribute.EpisodeDTO.Builderwriters(Iterable<String> elements)Sets or replaces all elements forwriterslist.
-
-
-
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.Episodeinstance.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder 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.EpisodeDTOinstance.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
absoluteNumber
public final EpisodeDTO.Builder absoluteNumber(@Nullable Long absoluteNumber)
Initializes the value for theabsoluteNumberattribute.- Parameters:
absoluteNumber- The value for absoluteNumber (can benull)- Returns:
thisbuilder for use in a chained invocation
-
airedEpisodeNumber
public final EpisodeDTO.Builder airedEpisodeNumber(@Nullable Long airedEpisodeNumber)
Initializes the value for theairedEpisodeNumberattribute.- Parameters:
airedEpisodeNumber- The value for airedEpisodeNumber (can benull)- Returns:
thisbuilder for use in a chained invocation
-
airedSeason
public final EpisodeDTO.Builder airedSeason(@Nullable Long airedSeason)
Initializes the value for theairedSeasonattribute.- Parameters:
airedSeason- The value for airedSeason (can benull)- Returns:
thisbuilder for use in a chained invocation
-
airsAfterSeason
public final EpisodeDTO.Builder airsAfterSeason(@Nullable Long airsAfterSeason)
Initializes the value for theairsAfterSeasonattribute.- Parameters:
airsAfterSeason- The value for airsAfterSeason (can benull)- Returns:
thisbuilder for use in a chained invocation
-
airsBeforeEpisode
public final EpisodeDTO.Builder airsBeforeEpisode(@Nullable Long airsBeforeEpisode)
Initializes the value for theairsBeforeEpisodeattribute.- Parameters:
airsBeforeEpisode- The value for airsBeforeEpisode (can benull)- Returns:
thisbuilder for use in a chained invocation
-
airsBeforeSeason
public final EpisodeDTO.Builder airsBeforeSeason(@Nullable Long airsBeforeSeason)
Initializes the value for theairsBeforeSeasonattribute.- Parameters:
airsBeforeSeason- The value for airsBeforeSeason (can benull)- Returns:
thisbuilder for use in a chained invocation
-
director
@Deprecated public final EpisodeDTO.Builder director(@Nullable String director)
Deprecated.Initializes the value for thedirectorattribute.- Parameters:
director- The value for director (can benull)- Returns:
thisbuilder for use in a chained invocation
-
addDirectors
public final EpisodeDTO.Builder addDirectors(String element)
Adds one element todirectorslist.- Parameters:
element- A directors element- Returns:
thisbuilder for use in a chained invocation
-
addDirectors
public final EpisodeDTO.Builder addDirectors(String... elements)
Adds elements todirectorslist.- Parameters:
elements- An array of directors elements- Returns:
thisbuilder for use in a chained invocation
-
directors
public final EpisodeDTO.Builder directors(Iterable<String> elements)
Sets or replaces all elements fordirectorslist.- Parameters:
elements- An iterable of directors elements- Returns:
thisbuilder for use in a chained invocation
-
addAllDirectors
public final EpisodeDTO.Builder addAllDirectors(Iterable<String> elements)
Adds elements todirectorslist.- Parameters:
elements- An iterable of directors elements- Returns:
thisbuilder for use in a chained invocation
-
dvdChapter
public final EpisodeDTO.Builder dvdChapter(@Nullable Long dvdChapter)
Initializes the value for thedvdChapterattribute.- Parameters:
dvdChapter- The value for dvdChapter (can benull)- Returns:
thisbuilder for use in a chained invocation
-
dvdDiscid
public final EpisodeDTO.Builder dvdDiscid(@Nullable String dvdDiscid)
Initializes the value for thedvdDiscidattribute.- Parameters:
dvdDiscid- The value for dvdDiscid (can benull)- Returns:
thisbuilder for use in a chained invocation
-
dvdEpisodeNumber
public final EpisodeDTO.Builder dvdEpisodeNumber(@Nullable Long dvdEpisodeNumber)
Initializes the value for thedvdEpisodeNumberattribute.- Parameters:
dvdEpisodeNumber- The value for dvdEpisodeNumber (can benull)- Returns:
thisbuilder for use in a chained invocation
-
dvdSeason
public final EpisodeDTO.Builder dvdSeason(@Nullable Long dvdSeason)
Initializes the value for thedvdSeasonattribute.- Parameters:
dvdSeason- The value for dvdSeason (can benull)- Returns:
thisbuilder for use in a chained invocation
-
episodeName
public final EpisodeDTO.Builder episodeName(@Nullable String episodeName)
Initializes the value for theepisodeNameattribute.- Parameters:
episodeName- The value for episodeName (can benull)- Returns:
thisbuilder for use in a chained invocation
-
filename
public final EpisodeDTO.Builder filename(@Nullable String filename)
Initializes the value for thefilenameattribute.- Parameters:
filename- The value for filename (can benull)- Returns:
thisbuilder for use in a chained invocation
-
firstAired
public final EpisodeDTO.Builder firstAired(@Nullable String firstAired)
Initializes the value for thefirstAiredattribute.- Parameters:
firstAired- The value for firstAired (can benull)- Returns:
thisbuilder for use in a chained invocation
-
addGuestStars
public final EpisodeDTO.Builder addGuestStars(String element)
Adds one element toguestStarslist.- Parameters:
element- A guestStars element- Returns:
thisbuilder for use in a chained invocation
-
addGuestStars
public final EpisodeDTO.Builder addGuestStars(String... elements)
Adds elements toguestStarslist.- Parameters:
elements- An array of guestStars elements- Returns:
thisbuilder for use in a chained invocation
-
guestStars
public final EpisodeDTO.Builder guestStars(Iterable<String> elements)
Sets or replaces all elements forguestStarslist.- Parameters:
elements- An iterable of guestStars elements- Returns:
thisbuilder for use in a chained invocation
-
addAllGuestStars
public final EpisodeDTO.Builder addAllGuestStars(Iterable<String> elements)
Adds elements toguestStarslist.- Parameters:
elements- An iterable of guestStars elements- Returns:
thisbuilder for use in a chained invocation
-
id
public final EpisodeDTO.Builder id(@Nullable Long id)
Initializes the value for theidattribute.- Parameters:
id- The value for id (can benull)- Returns:
thisbuilder for use in a chained invocation
-
imdbId
public final EpisodeDTO.Builder imdbId(@Nullable String imdbId)
Initializes the value for theimdbIdattribute.- Parameters:
imdbId- The value for imdbId (can benull)- Returns:
thisbuilder for use in a chained invocation
-
lastUpdated
public final EpisodeDTO.Builder lastUpdated(@Nullable Long lastUpdated)
Initializes the value for thelastUpdatedattribute.- Parameters:
lastUpdated- The value for lastUpdated (can benull)- Returns:
thisbuilder for use in a chained invocation
-
lastUpdatedBy
public final EpisodeDTO.Builder lastUpdatedBy(@Nullable String lastUpdatedBy)
Initializes the value for thelastUpdatedByattribute.- Parameters:
lastUpdatedBy- The value for lastUpdatedBy (can benull)- Returns:
thisbuilder for use in a chained invocation
-
overview
public final EpisodeDTO.Builder overview(@Nullable String overview)
Initializes the value for theoverviewattribute.- Parameters:
overview- The value for overview (can benull)- Returns:
thisbuilder for use in a chained invocation
-
productionCode
public final EpisodeDTO.Builder productionCode(@Nullable String productionCode)
Initializes the value for theproductionCodeattribute.- Parameters:
productionCode- The value for productionCode (can benull)- Returns:
thisbuilder for use in a chained invocation
-
seriesId
public final EpisodeDTO.Builder seriesId(@Nullable String seriesId)
Initializes the value for theseriesIdattribute.- Parameters:
seriesId- The value for seriesId (can benull)- Returns:
thisbuilder for use in a chained invocation
-
showUrl
public final EpisodeDTO.Builder showUrl(@Nullable String showUrl)
Initializes the value for theshowUrlattribute.- Parameters:
showUrl- The value for showUrl (can benull)- Returns:
thisbuilder for use in a chained invocation
-
siteRating
public final EpisodeDTO.Builder siteRating(@Nullable Double siteRating)
Initializes the value for thesiteRatingattribute.- Parameters:
siteRating- The value for siteRating (can benull)- Returns:
thisbuilder for use in a chained invocation
-
siteRatingCount
public final EpisodeDTO.Builder siteRatingCount(@Nullable Long siteRatingCount)
Initializes the value for thesiteRatingCountattribute.- Parameters:
siteRatingCount- The value for siteRatingCount (can benull)- Returns:
thisbuilder for use in a chained invocation
-
thumbAdded
public final EpisodeDTO.Builder thumbAdded(@Nullable String thumbAdded)
Initializes the value for thethumbAddedattribute.- Parameters:
thumbAdded- The value for thumbAdded (can benull)- Returns:
thisbuilder for use in a chained invocation
-
thumbAuthor
public final EpisodeDTO.Builder thumbAuthor(@Nullable Long thumbAuthor)
Initializes the value for thethumbAuthorattribute.- Parameters:
thumbAuthor- The value for thumbAuthor (can benull)- Returns:
thisbuilder for use in a chained invocation
-
thumbHeight
public final EpisodeDTO.Builder thumbHeight(@Nullable String thumbHeight)
Initializes the value for thethumbHeightattribute.- Parameters:
thumbHeight- The value for thumbHeight (can benull)- Returns:
thisbuilder for use in a chained invocation
-
thumbWidth
public final EpisodeDTO.Builder thumbWidth(@Nullable String thumbWidth)
Initializes the value for thethumbWidthattribute.- Parameters:
thumbWidth- The value for thumbWidth (can benull)- Returns:
thisbuilder for use in a chained invocation
-
addWriters
public final EpisodeDTO.Builder addWriters(String element)
Adds one element towriterslist.- Parameters:
element- A writers element- Returns:
thisbuilder for use in a chained invocation
-
addWriters
public final EpisodeDTO.Builder addWriters(String... elements)
Adds elements towriterslist.- Parameters:
elements- An array of writers elements- Returns:
thisbuilder for use in a chained invocation
-
writers
public final EpisodeDTO.Builder writers(Iterable<String> elements)
Sets or replaces all elements forwriterslist.- Parameters:
elements- An iterable of writers elements- Returns:
thisbuilder for use in a chained invocation
-
addAllWriters
public final EpisodeDTO.Builder addAllWriters(Iterable<String> elements)
Adds elements towriterslist.- Parameters:
elements- An iterable of writers elements- Returns:
thisbuilder 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
-
-