579 lines
12 KiB
Java
579 lines
12 KiB
Java
|
||
package com.baeldung.model;
|
||
|
||
import javax.xml.bind.annotation.XmlAccessType;
|
||
import javax.xml.bind.annotation.XmlAccessorType;
|
||
import javax.xml.bind.annotation.XmlType;
|
||
|
||
|
||
@XmlAccessorType(XmlAccessType.FIELD)
|
||
@XmlType(name = "movie", propOrder = {
|
||
"actors",
|
||
"awards",
|
||
"country",
|
||
"director",
|
||
"genre",
|
||
"imdbID",
|
||
"imdbRating",
|
||
"imdbVotes",
|
||
"language",
|
||
"metascore",
|
||
"plot",
|
||
"poster",
|
||
"rated",
|
||
"released",
|
||
"response",
|
||
"runtime",
|
||
"title",
|
||
"type",
|
||
"writer",
|
||
"year"
|
||
})
|
||
public class Movie {
|
||
|
||
protected String actors;
|
||
protected String awards;
|
||
protected String country;
|
||
protected String director;
|
||
protected String genre;
|
||
protected String imdbID;
|
||
protected String imdbRating;
|
||
protected String imdbVotes;
|
||
protected String language;
|
||
protected String metascore;
|
||
protected String plot;
|
||
protected String poster;
|
||
protected String rated;
|
||
protected String released;
|
||
protected String response;
|
||
protected String runtime;
|
||
protected String title;
|
||
protected String type;
|
||
protected String writer;
|
||
protected String year;
|
||
|
||
/**
|
||
* Recupera il valore della propriet<65> actors.
|
||
*
|
||
* @return
|
||
* possible object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public String getActors() {
|
||
return actors;
|
||
}
|
||
|
||
/**
|
||
* Imposta il valore della propriet<65> actors.
|
||
*
|
||
* @param value
|
||
* allowed object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public void setActors(String value) {
|
||
this.actors = value;
|
||
}
|
||
|
||
/**
|
||
* Recupera il valore della propriet<65> awards.
|
||
*
|
||
* @return
|
||
* possible object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public String getAwards() {
|
||
return awards;
|
||
}
|
||
|
||
/**
|
||
* Imposta il valore della propriet<65> awards.
|
||
*
|
||
* @param value
|
||
* allowed object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public void setAwards(String value) {
|
||
this.awards = value;
|
||
}
|
||
|
||
/**
|
||
* Recupera il valore della propriet<65> country.
|
||
*
|
||
* @return
|
||
* possible object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public String getCountry() {
|
||
return country;
|
||
}
|
||
|
||
/**
|
||
* Imposta il valore della propriet<65> country.
|
||
*
|
||
* @param value
|
||
* allowed object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public void setCountry(String value) {
|
||
this.country = value;
|
||
}
|
||
|
||
/**
|
||
* Recupera il valore della propriet<65> director.
|
||
*
|
||
* @return
|
||
* possible object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public String getDirector() {
|
||
return director;
|
||
}
|
||
|
||
/**
|
||
* Imposta il valore della propriet<65> director.
|
||
*
|
||
* @param value
|
||
* allowed object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public void setDirector(String value) {
|
||
this.director = value;
|
||
}
|
||
|
||
/**
|
||
* Recupera il valore della propriet<65> genre.
|
||
*
|
||
* @return
|
||
* possible object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public String getGenre() {
|
||
return genre;
|
||
}
|
||
|
||
/**
|
||
* Imposta il valore della propriet<65> genre.
|
||
*
|
||
* @param value
|
||
* allowed object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public void setGenre(String value) {
|
||
this.genre = value;
|
||
}
|
||
|
||
/**
|
||
* Recupera il valore della propriet<65> imdbID.
|
||
*
|
||
* @return
|
||
* possible object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public String getImdbID() {
|
||
return imdbID;
|
||
}
|
||
|
||
/**
|
||
* Imposta il valore della propriet<65> imdbID.
|
||
*
|
||
* @param value
|
||
* allowed object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public void setImdbID(String value) {
|
||
this.imdbID = value;
|
||
}
|
||
|
||
/**
|
||
* Recupera il valore della propriet<65> imdbRating.
|
||
*
|
||
* @return
|
||
* possible object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public String getImdbRating() {
|
||
return imdbRating;
|
||
}
|
||
|
||
/**
|
||
* Imposta il valore della propriet<65> imdbRating.
|
||
*
|
||
* @param value
|
||
* allowed object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public void setImdbRating(String value) {
|
||
this.imdbRating = value;
|
||
}
|
||
|
||
/**
|
||
* Recupera il valore della propriet<65> imdbVotes.
|
||
*
|
||
* @return
|
||
* possible object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public String getImdbVotes() {
|
||
return imdbVotes;
|
||
}
|
||
|
||
/**
|
||
* Imposta il valore della propriet<65> imdbVotes.
|
||
*
|
||
* @param value
|
||
* allowed object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public void setImdbVotes(String value) {
|
||
this.imdbVotes = value;
|
||
}
|
||
|
||
/**
|
||
* Recupera il valore della propriet<65> language.
|
||
*
|
||
* @return
|
||
* possible object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public String getLanguage() {
|
||
return language;
|
||
}
|
||
|
||
/**
|
||
* Imposta il valore della propriet<65> language.
|
||
*
|
||
* @param value
|
||
* allowed object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public void setLanguage(String value) {
|
||
this.language = value;
|
||
}
|
||
|
||
/**
|
||
* Recupera il valore della propriet<65> metascore.
|
||
*
|
||
* @return
|
||
* possible object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public String getMetascore() {
|
||
return metascore;
|
||
}
|
||
|
||
/**
|
||
* Imposta il valore della propriet<65> metascore.
|
||
*
|
||
* @param value
|
||
* allowed object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public void setMetascore(String value) {
|
||
this.metascore = value;
|
||
}
|
||
|
||
/**
|
||
* Recupera il valore della propriet<65> plot.
|
||
*
|
||
* @return
|
||
* possible object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public String getPlot() {
|
||
return plot;
|
||
}
|
||
|
||
/**
|
||
* Imposta il valore della propriet<65> plot.
|
||
*
|
||
* @param value
|
||
* allowed object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public void setPlot(String value) {
|
||
this.plot = value;
|
||
}
|
||
|
||
/**
|
||
* Recupera il valore della propriet<65> poster.
|
||
*
|
||
* @return
|
||
* possible object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public String getPoster() {
|
||
return poster;
|
||
}
|
||
|
||
/**
|
||
* Imposta il valore della propriet<65> poster.
|
||
*
|
||
* @param value
|
||
* allowed object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public void setPoster(String value) {
|
||
this.poster = value;
|
||
}
|
||
|
||
/**
|
||
* Recupera il valore della propriet<65> rated.
|
||
*
|
||
* @return
|
||
* possible object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public String getRated() {
|
||
return rated;
|
||
}
|
||
|
||
/**
|
||
* Imposta il valore della propriet<65> rated.
|
||
*
|
||
* @param value
|
||
* allowed object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public void setRated(String value) {
|
||
this.rated = value;
|
||
}
|
||
|
||
/**
|
||
* Recupera il valore della propriet<65> released.
|
||
*
|
||
* @return
|
||
* possible object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public String getReleased() {
|
||
return released;
|
||
}
|
||
|
||
/**
|
||
* Imposta il valore della propriet<65> released.
|
||
*
|
||
* @param value
|
||
* allowed object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public void setReleased(String value) {
|
||
this.released = value;
|
||
}
|
||
|
||
/**
|
||
* Recupera il valore della propriet<65> response.
|
||
*
|
||
* @return
|
||
* possible object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public String getResponse() {
|
||
return response;
|
||
}
|
||
|
||
/**
|
||
* Imposta il valore della propriet<65> response.
|
||
*
|
||
* @param value
|
||
* allowed object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public void setResponse(String value) {
|
||
this.response = value;
|
||
}
|
||
|
||
/**
|
||
* Recupera il valore della propriet<65> runtime.
|
||
*
|
||
* @return
|
||
* possible object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public String getRuntime() {
|
||
return runtime;
|
||
}
|
||
|
||
/**
|
||
* Imposta il valore della propriet<65> runtime.
|
||
*
|
||
* @param value
|
||
* allowed object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public void setRuntime(String value) {
|
||
this.runtime = value;
|
||
}
|
||
|
||
/**
|
||
* Recupera il valore della propriet<65> title.
|
||
*
|
||
* @return
|
||
* possible object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public String getTitle() {
|
||
return title;
|
||
}
|
||
|
||
/**
|
||
* Imposta il valore della propriet<65> title.
|
||
*
|
||
* @param value
|
||
* allowed object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public void setTitle(String value) {
|
||
this.title = value;
|
||
}
|
||
|
||
/**
|
||
* Recupera il valore della propriet<65> type.
|
||
*
|
||
* @return
|
||
* possible object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public String getType() {
|
||
return type;
|
||
}
|
||
|
||
/**
|
||
* Imposta il valore della propriet<65> type.
|
||
*
|
||
* @param value
|
||
* allowed object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public void setType(String value) {
|
||
this.type = value;
|
||
}
|
||
|
||
/**
|
||
* Recupera il valore della propriet<65> writer.
|
||
*
|
||
* @return
|
||
* possible object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public String getWriter() {
|
||
return writer;
|
||
}
|
||
|
||
/**
|
||
* Imposta il valore della propriet<65> writer.
|
||
*
|
||
* @param value
|
||
* allowed object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public void setWriter(String value) {
|
||
this.writer = value;
|
||
}
|
||
|
||
/**
|
||
* Recupera il valore della propriet<65> year.
|
||
*
|
||
* @return
|
||
* possible object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public String getYear() {
|
||
return year;
|
||
}
|
||
|
||
/**
|
||
* Imposta il valore della propriet<65> year.
|
||
*
|
||
* @param value
|
||
* allowed object is
|
||
* {@link String }
|
||
*
|
||
*/
|
||
public void setYear(String value) {
|
||
this.year = value;
|
||
}
|
||
|
||
@Override
|
||
public String toString() {
|
||
return "Movie{" +
|
||
"actors='" + actors + '\'' +
|
||
", awards='" + awards + '\'' +
|
||
", country='" + country + '\'' +
|
||
", director='" + director + '\'' +
|
||
", genre='" + genre + '\'' +
|
||
", imdbID='" + imdbID + '\'' +
|
||
", imdbRating='" + imdbRating + '\'' +
|
||
", imdbVotes='" + imdbVotes + '\'' +
|
||
", language='" + language + '\'' +
|
||
", metascore='" + metascore + '\'' +
|
||
", poster='" + poster + '\'' +
|
||
", rated='" + rated + '\'' +
|
||
", released='" + released + '\'' +
|
||
", response='" + response + '\'' +
|
||
", runtime='" + runtime + '\'' +
|
||
", title='" + title + '\'' +
|
||
", type='" + type + '\'' +
|
||
", writer='" + writer + '\'' +
|
||
", year='" + year + '\'' +
|
||
'}';
|
||
}
|
||
|
||
@Override
|
||
public boolean equals(Object o) {
|
||
if (this == o) return true;
|
||
if (o == null || getClass() != o.getClass()) return false;
|
||
|
||
Movie movie = (Movie) o;
|
||
|
||
if (imdbID != null ? !imdbID.equals(movie.imdbID) : movie.imdbID != null) return false;
|
||
return title != null ? title.equals(movie.title) : movie.title == null;
|
||
|
||
}
|
||
|
||
@Override
|
||
public int hashCode() {
|
||
int result = imdbID != null ? imdbID.hashCode() : 0;
|
||
result = 31 * result + (title != null ? title.hashCode() : 0);
|
||
return result;
|
||
}
|
||
}
|