package eu.eudat.models.rda; import java.io.Serializable; import java.util.HashMap; import java.util.Map; import com.fasterxml.jackson.annotation.*; /** * The Contributor_id Schema *

* * */ @JsonInclude(JsonInclude.Include.NON_NULL) @JsonPropertyOrder({ "identifier", "type" }) @JsonIgnoreProperties(ignoreUnknown = true) public class ContributorId implements Serializable { /** * The Contributor Identifier Schema *

* Identifier for a contact person * (Required) * */ @JsonProperty("identifier") @JsonPropertyDescription("Identifier for a contact person") private String identifier; /** * The Contributor Identifier Type Schema *

* Identifier type. Allowed values: orcid, isni, openid, other * (Required) * */ @JsonProperty("type") @JsonPropertyDescription("Identifier type. Allowed values: orcid, isni, openid, other") private ContributorId.Type type; @JsonIgnore private Map additionalProperties = new HashMap(); private final static long serialVersionUID = 3089650417960767482L; /** * The Contributor Identifier Schema *

* Identifier for a contact person * (Required) * */ @JsonProperty("identifier") public String getIdentifier() { return identifier; } /** * The Contributor Identifier Schema *

* Identifier for a contact person * (Required) * */ @JsonProperty("identifier") public void setIdentifier(String identifier) { this.identifier = identifier; } /** * The Contributor Identifier Type Schema *

* Identifier type. Allowed values: orcid, isni, openid, other * (Required) * */ @JsonProperty("type") public ContributorId.Type getType() { return type; } /** * The Contributor Identifier Type Schema *

* Identifier type. Allowed values: orcid, isni, openid, other * (Required) * */ @JsonProperty("type") public void setType(ContributorId.Type type) { this.type = type; } @JsonProperty("additional_properties") public Map getAdditionalProperties() { return this.additionalProperties; } @JsonProperty("additional_properties") public void setAdditionalProperty(String name, Object value) { this.additionalProperties.put(name, value); } public enum Type { ORCID("orcid"), ISNI("isni"), OPENID("openid"), OTHER("other"); private final String value; private final static Map CONSTANTS = new HashMap(); static { for (ContributorId.Type c: values()) { CONSTANTS.put(c.value, c); } } private Type(String value) { this.value = value; } @Override public String toString() { return this.value; } @JsonValue public String value() { return this.value; } @JsonCreator public static ContributorId.Type fromValue(String value) { ContributorId.Type constant = CONSTANTS.get(value); if (constant == null) { throw new IllegalArgumentException(value); } else { return constant; } } } }