212 lines
5.7 KiB
Java
212 lines
5.7 KiB
Java
package org.opencdmp.elastic.data;
|
|
|
|
import gr.cite.tools.elastic.ElasticConstants;
|
|
import org.opencdmp.commons.enums.DmpAccessType;
|
|
import org.opencdmp.commons.enums.DmpStatus;
|
|
import org.opencdmp.commons.enums.DmpVersionStatus;
|
|
import org.opencdmp.elastic.data.nested.NestedCollaboratorElasticEntity;
|
|
import org.opencdmp.elastic.data.nested.NestedDescriptionElasticEntity;
|
|
import org.opencdmp.elastic.data.nested.NestedDoiElasticEntity;
|
|
import org.opencdmp.elastic.data.nested.NestedReferenceElasticEntity;
|
|
import org.springframework.data.annotation.Id;
|
|
import org.springframework.data.elasticsearch.annotations.*;
|
|
|
|
import java.util.Date;
|
|
import java.util.List;
|
|
import java.util.UUID;
|
|
|
|
@Document(indexName = "dmp")
|
|
public class DmpElasticEntity {
|
|
@Id
|
|
@Field(value = DmpElasticEntity._id, type = FieldType.Keyword)
|
|
private UUID id;
|
|
public final static String _id = "id";
|
|
|
|
@Field(value = DmpElasticEntity._tenantId, type = FieldType.Keyword)
|
|
private UUID tenantId;
|
|
public final static String _tenantId = "tenantId";
|
|
|
|
@MultiField(mainField = @Field(value = DmpElasticEntity._label, type = FieldType.Text), otherFields = @InnerField(suffix = ElasticConstants.SubFields.keyword, type = FieldType.Keyword))
|
|
private String label;
|
|
public final static String _label = "label";
|
|
|
|
@Field(value = DmpElasticEntity._description, type = FieldType.Text)
|
|
private String description;
|
|
public final static String _description = "description";
|
|
|
|
@Field(value = DmpElasticEntity._version, type = FieldType.Keyword)
|
|
private Short version;
|
|
public final static String _version = "version";
|
|
|
|
@Field(value = DmpElasticEntity._status, type = FieldType.Short)
|
|
private DmpStatus status;
|
|
public final static String _status = "status";
|
|
|
|
@Field(value = DmpElasticEntity._accessType, type = FieldType.Short)
|
|
private DmpAccessType accessType;
|
|
public final static String _accessType = "accessType";
|
|
@Field(value = DmpElasticEntity._versionStatus, type = FieldType.Short)
|
|
private DmpVersionStatus versionStatus;
|
|
public final static String _versionStatus = "versionStatus";
|
|
|
|
@Field(value = DmpElasticEntity._language, type = FieldType.Keyword)
|
|
private String language;
|
|
public final static String _language = "language";
|
|
|
|
@Field(value = DmpElasticEntity._blueprintId, type = FieldType.Keyword)
|
|
private UUID blueprintId;
|
|
public final static String _blueprintId = "blueprintId";
|
|
|
|
@Field(value = DmpElasticEntity._groupId, type = FieldType.Keyword)
|
|
private UUID groupId;
|
|
public final static String _groupId = "groupId";
|
|
|
|
@Field(value = DmpElasticEntity._finalizedAt, type = FieldType.Date)
|
|
private Date finalizedAt;
|
|
public final static String _finalizedAt = "finalizedAt";
|
|
|
|
@Field(value = DmpElasticEntity._references, type = FieldType.Nested)
|
|
private List<NestedReferenceElasticEntity> references;
|
|
public final static String _references = "references";
|
|
|
|
@Field(value = DmpElasticEntity._collaborators, type = FieldType.Nested)
|
|
private List<NestedCollaboratorElasticEntity> collaborators;
|
|
public final static String _collaborators = "collaborators";
|
|
|
|
@Field(value = DmpElasticEntity._descriptions, type = FieldType.Nested)
|
|
private List<NestedDescriptionElasticEntity> descriptions;
|
|
public final static String _descriptions = "descriptions";
|
|
|
|
@Field(value = DmpElasticEntity._dois, type = FieldType.Nested)
|
|
private List<NestedDoiElasticEntity> dois;
|
|
public final static String _dois = "dois";
|
|
|
|
public UUID getId() {
|
|
return this.id;
|
|
}
|
|
|
|
public void setId(UUID id) {
|
|
this.id = id;
|
|
}
|
|
|
|
public UUID getTenantId() {
|
|
return this.tenantId;
|
|
}
|
|
|
|
public void setTenantId(UUID tenantId) {
|
|
this.tenantId = tenantId;
|
|
}
|
|
|
|
public String getLabel() {
|
|
return this.label;
|
|
}
|
|
|
|
public void setLabel(String label) {
|
|
this.label = label;
|
|
}
|
|
|
|
public String getDescription() {
|
|
return this.description;
|
|
}
|
|
|
|
public void setDescription(String description) {
|
|
this.description = description;
|
|
}
|
|
|
|
public Short getVersion() {
|
|
return this.version;
|
|
}
|
|
|
|
public void setVersion(Short version) {
|
|
this.version = version;
|
|
}
|
|
|
|
public DmpStatus getStatus() {
|
|
return this.status;
|
|
}
|
|
|
|
public void setStatus(DmpStatus status) {
|
|
this.status = status;
|
|
}
|
|
|
|
public DmpAccessType getAccessType() {
|
|
return this.accessType;
|
|
}
|
|
|
|
public void setAccessType(DmpAccessType accessType) {
|
|
this.accessType = accessType;
|
|
}
|
|
|
|
public String getLanguage() {
|
|
return this.language;
|
|
}
|
|
|
|
public void setLanguage(String language) {
|
|
this.language = language;
|
|
}
|
|
|
|
public UUID getBlueprintId() {
|
|
return this.blueprintId;
|
|
}
|
|
|
|
public void setBlueprintId(UUID blueprintId) {
|
|
this.blueprintId = blueprintId;
|
|
}
|
|
|
|
public UUID getGroupId() {
|
|
return this.groupId;
|
|
}
|
|
|
|
public void setGroupId(UUID groupId) {
|
|
this.groupId = groupId;
|
|
}
|
|
|
|
public Date getFinalizedAt() {
|
|
return this.finalizedAt;
|
|
}
|
|
|
|
public void setFinalizedAt(Date finalizedAt) {
|
|
this.finalizedAt = finalizedAt;
|
|
}
|
|
|
|
public List<NestedReferenceElasticEntity> getReferences() {
|
|
return this.references;
|
|
}
|
|
|
|
public void setReferences(List<NestedReferenceElasticEntity> references) {
|
|
this.references = references;
|
|
}
|
|
|
|
public List<NestedCollaboratorElasticEntity> getCollaborators() {
|
|
return this.collaborators;
|
|
}
|
|
|
|
public void setCollaborators(List<NestedCollaboratorElasticEntity> collaborators) {
|
|
this.collaborators = collaborators;
|
|
}
|
|
|
|
public List<NestedDescriptionElasticEntity> getDescriptions() {
|
|
return this.descriptions;
|
|
}
|
|
|
|
public void setDescriptions(List<NestedDescriptionElasticEntity> descriptions) {
|
|
this.descriptions = descriptions;
|
|
}
|
|
|
|
public List<NestedDoiElasticEntity> getDois() {
|
|
return this.dois;
|
|
}
|
|
|
|
public void setDois(List<NestedDoiElasticEntity> dois) {
|
|
this.dois = dois;
|
|
}
|
|
|
|
public DmpVersionStatus getVersionStatus() {
|
|
return this.versionStatus;
|
|
}
|
|
|
|
public void setVersionStatus(DmpVersionStatus versionStatus) {
|
|
this.versionStatus = versionStatus;
|
|
}
|
|
}
|