vigliom 2 years ago
parent
commit
de24f09d08
3 changed files with 97 additions and 1 deletions
  1. +96
    -0
      src/main/java/com/jorpelu/model/Film.java
  2. +1
    -1
      target/classes/META-INF/maven/com.jorpelu/MovieAdviser/pom.properties
  3. BIN
      target/classes/com/jorpelu/model/Film.class

+ 96
- 0
src/main/java/com/jorpelu/model/Film.java View File

@ -0,0 +1,96 @@
package com.jorpelu.model;
import java.util.List;
public class Film {
private long id;
private String title;
private String year;
private List<String> generos;
public Film() {
}
public Film(long id, String title, String year, List<String> generos) {
super();
this.id = id;
this.title = title;
this.year = year;
this.generos = generos;
}
public long getId() {
return id;
}
public void setId(long id) {
this.id = id;
}
public String getTitle() {
return title;
}
public void setTitle(String title) {
this.title = title;
}
public String getYear() {
return year;
}
public void setYear(String year) {
this.year = year;
}
public List<String> getGeneros() {
return generos;
}
public void setGeneros(List<String> generos) {
this.generos = generos;
}
@Override
public int hashCode() {
final int prime = 31;
int result = 1;
result = prime * result + ((generos == null) ? 0 : generos.hashCode());
result = prime * result + (int) (id ^ (id >>> 32));
result = prime * result + ((title == null) ? 0 : title.hashCode());
result = prime * result + ((year == null) ? 0 : year.hashCode());
return result;
}
@Override
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null)
return false;
if (getClass() != obj.getClass())
return false;
Film other = (Film) obj;
if (generos == null) {
if (other.generos != null)
return false;
} else if (!generos.equals(other.generos))
return false;
if (id != other.id)
return false;
if (title == null) {
if (other.title != null)
return false;
} else if (!title.equals(other.title))
return false;
if (year == null) {
if (other.year != null)
return false;
} else if (!year.equals(other.year))
return false;
return true;
}
}

+ 1
- 1
target/classes/META-INF/maven/com.jorpelu/MovieAdviser/pom.properties View File

@ -1,5 +1,5 @@
#Generated by Maven Integration for Eclipse
#Tue Nov 08 15:52:36 CET 2022
#Tue Nov 08 16:22:35 CET 2022
m2e.projectLocation=C\:\\Users\\jorge\\OneDrive\\Documentos\\ProyectosSPRING\\MovieAdviser
m2e.projectName=MovieAdviser
groupId=com.jorpelu


BIN
target/classes/com/jorpelu/model/Film.class View File


Loading…
Cancel
Save