Interface Movie
-
- All Known Implementing Classes:
MovieDTO
public interface MovieInterface representing a Movie data transfer object.
The methods of this class provide easy access to all movie related data which was returned by the remote service in JSON format. Please note that, as the remote service declares all of the properties to be optional, most of the methods are marked asNullable. Methods returning collection-based values however will return an empty collection in case no corresponding data was received.
The sole purpose of these DTO objects is to encapsulate the exact raw JSON data as received from the remote service in order to facilitate API integration by working with simple Java POJO's instead of nested JSON nodes. Although there will be no intense post-processing of the actual JSON values a type-casting may be applied to some of them to improve the usability and relieve the API user of this task.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interfaceMovie.ArtworkInterface representing a movies Artwork data transfer object.static interfaceMovie.GenreInterface representing a movies Genre data transfer object.static interfaceMovie.PeopleInterface representing a movies People data transfer object.static interfaceMovie.ReleaseDateInterface representing a movies ReleaseDate data transfer object.static interfaceMovie.RemoteIdInterface representing a movies RemoteId data transfer object.static interfaceMovie.TrailerInterface representing a movies Trailer data transfer object.static interfaceMovie.TranslationInterface representing a movies Translation data transfer object.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description List<Movie.People>getActors()Get all objects of the {data.people.actors} JSON property in a listList<Movie.Artwork>getArtworks()Get all objects of the {data.artworks} JSON property in a listList<Movie.People>getDirectors()Get all objects of the {data.people.directors} JSON property in a listList<Movie.Genre>getGenres()Get all objects of the {data.genres} JSON property in a listLonggetId()Get the value of the {data.id} JSON propertyList<Movie.People>getProducers()Get all objects of the {data.people.producers} JSON property in a listList<Movie.ReleaseDate>getReleaseDates()Get all objects of the {data.release_dates} JSON property in a listList<Movie.RemoteId>getRemoteIds()Get all objects of the {data.remoteids} JSON property in a listLonggetRuntime()Get the value of the {data.runtime} JSON propertyList<Movie.Trailer>getTrailers()Get all objects of the {data.trailers} JSON property in a listList<Movie.Translation>getTranslations()Get all objects of the {data.translations} JSON property in a listStringgetUrl()Get the value of the {data.url} JSON propertyList<Movie.People>getWriters()Get all objects of the {data.people.writers} JSON property in a list
-
-
-
Method Detail
-
getArtworks
List<Movie.Artwork> getArtworks()
Get all objects of the {data.artworks} JSON property in a list- Returns:
- The
artworksproperty from the received JSON as list
-
getGenres
List<Movie.Genre> getGenres()
Get all objects of the {data.genres} JSON property in a list- Returns:
- The
genresproperty from the received JSON as list
-
getId
@Nullable Long getId()
Get the value of the {data.id} JSON property- Returns:
- The
idproperty from the received JSON
-
getActors
List<Movie.People> getActors()
Get all objects of the {data.people.actors} JSON property in a list- Returns:
- The
actorsproperty from the received JSONs people-node as list
-
getDirectors
List<Movie.People> getDirectors()
Get all objects of the {data.people.directors} JSON property in a list- Returns:
- The
directorsproperty from the received JSONs people-node as list
-
getProducers
List<Movie.People> getProducers()
Get all objects of the {data.people.producers} JSON property in a list- Returns:
- The
producersproperty from the received JSONs people-node as list
-
getWriters
List<Movie.People> getWriters()
Get all objects of the {data.people.writers} JSON property in a list- Returns:
- The
writersproperty from the received JSONs people-node as list
-
getReleaseDates
List<Movie.ReleaseDate> getReleaseDates()
Get all objects of the {data.release_dates} JSON property in a list- Returns:
- The
release_datesproperty from the received JSON as list
-
getRemoteIds
List<Movie.RemoteId> getRemoteIds()
Get all objects of the {data.remoteids} JSON property in a list- Returns:
- The
remoteidsproperty from the received JSON as list
-
getRuntime
@Nullable Long getRuntime()
Get the value of the {data.runtime} JSON property- Returns:
- The
runtimeproperty from the received JSON
-
getTrailers
List<Movie.Trailer> getTrailers()
Get all objects of the {data.trailers} JSON property in a list- Returns:
- The
trailersproperty from the received JSON as list
-
getTranslations
List<Movie.Translation> getTranslations()
Get all objects of the {data.translations} JSON property in a list- Returns:
- The
translationsproperty from the received JSON as list
-
-