80 lines
1.9 KiB
Java
80 lines
1.9 KiB
Java
package eu.dnetlib.is.context.model;
|
|
|
|
import java.io.Serializable;
|
|
import java.util.Objects;
|
|
|
|
public class ConceptLevel2PK implements Serializable {
|
|
|
|
private static final long serialVersionUID = -5543486531261862945L;
|
|
|
|
private String id;
|
|
|
|
private String contextId;
|
|
|
|
private String categoryId;
|
|
|
|
private String conceptLevel0Id;
|
|
|
|
private String conceptLevel1Id;
|
|
|
|
public String getId() {
|
|
return id;
|
|
}
|
|
|
|
public void setId(final String id) {
|
|
this.id = id;
|
|
}
|
|
|
|
public String getContextId() {
|
|
return contextId;
|
|
}
|
|
|
|
public void setContextId(final String contextId) {
|
|
this.contextId = contextId;
|
|
}
|
|
|
|
public String getCategoryId() {
|
|
return categoryId;
|
|
}
|
|
|
|
public void setCategoryId(final String categoryId) {
|
|
this.categoryId = categoryId;
|
|
}
|
|
|
|
public String getConceptLevel0Id() {
|
|
return conceptLevel0Id;
|
|
}
|
|
|
|
public void setConceptLevel0Id(final String conceptLevel0Id) {
|
|
this.conceptLevel0Id = conceptLevel0Id;
|
|
}
|
|
|
|
public String getConceptLevel1Id() {
|
|
return conceptLevel1Id;
|
|
}
|
|
|
|
public void setConceptLevel1Id(final String conceptLevel1Id) {
|
|
this.conceptLevel1Id = conceptLevel1Id;
|
|
}
|
|
|
|
@Override
|
|
public int hashCode() {
|
|
return Objects.hash(categoryId, conceptLevel0Id, conceptLevel1Id, contextId, id);
|
|
}
|
|
|
|
@Override
|
|
public boolean equals(final Object obj) {
|
|
if (this == obj) { return true; }
|
|
if (!(obj instanceof ConceptLevel2PK)) { return false; }
|
|
final ConceptLevel2PK other = (ConceptLevel2PK) obj;
|
|
return Objects.equals(categoryId, other.categoryId) && Objects.equals(conceptLevel0Id, other.conceptLevel0Id)
|
|
&& Objects.equals(conceptLevel1Id, other.conceptLevel1Id) && Objects.equals(contextId, other.contextId) && Objects.equals(id, other.id);
|
|
}
|
|
|
|
@Override
|
|
public String toString() {
|
|
return String
|
|
.format("ConceptLevel2PK [id=%s, contextId=%s, categoryId=%s, conceptLevel0Id=%s, conceptLevel1Id=%s]", id, contextId, categoryId, conceptLevel0Id, conceptLevel1Id);
|
|
}
|
|
}
|