
com.ellucian.generated.eedm.sources.v6_0.Sources Maven / Gradle / Ivy
package com.ellucian.generated.eedm.sources.v6_0;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import javax.annotation.processing.Generated;
import com.ellucian.generated.eedm.academic_catalogs.v6_0.Metadata;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonPropertyDescription;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import com.fasterxml.jackson.annotation.JsonValue;
/**
* Sources
*
* Source of information.
*
*/
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonPropertyOrder({
"metadata",
"id",
"title",
"description",
"code",
"contexts",
"status"
})
@Generated("jsonschema2pojo")
public class Sources {
/**
* Metadata
*
* Metadata about the JSON payload
*
*/
@JsonProperty("metadata")
@JsonPropertyDescription("Metadata about the JSON payload")
private Metadata metadata;
/**
* ID
*
* The global identifier of the source
* (Required)
*
*/
@JsonProperty("id")
@JsonPropertyDescription("The global identifier of the source")
private String id;
/**
* Title
*
* The full name of the source.
* (Required)
*
*/
@JsonProperty("title")
@JsonPropertyDescription("The full name of the source.")
private String title;
/**
* Description
*
* The full description of the source.
*
*/
@JsonProperty("description")
@JsonPropertyDescription("The full description of the source.")
private String description;
/**
* code
*
* The code of the source.
*
*/
@JsonProperty("code")
@JsonPropertyDescription("The code of the source.")
private String code;
/**
* Context
*
* The context the source is used in.
*
*/
@JsonProperty("contexts")
@JsonPropertyDescription("The context the source is used in.")
private List contexts = new ArrayList();
/**
* Status
*
* The status of the source in this context.
* (Required)
*
*/
@JsonProperty("status")
@JsonPropertyDescription("The status of the source in this context.")
private Sources.Status status;
/**
* Metadata
*
* Metadata about the JSON payload
*
*/
@JsonProperty("metadata")
public Metadata getMetadata() {
return metadata;
}
/**
* Metadata
*
* Metadata about the JSON payload
*
*/
@JsonProperty("metadata")
public void setMetadata(Metadata metadata) {
this.metadata = metadata;
}
public Sources withMetadata(Metadata metadata) {
this.metadata = metadata;
return this;
}
/**
* ID
*
* The global identifier of the source
* (Required)
*
*/
@JsonProperty("id")
public String getId() {
return id;
}
/**
* ID
*
* The global identifier of the source
* (Required)
*
*/
@JsonProperty("id")
public void setId(String id) {
this.id = id;
}
public Sources withId(String id) {
this.id = id;
return this;
}
/**
* Title
*
* The full name of the source.
* (Required)
*
*/
@JsonProperty("title")
public String getTitle() {
return title;
}
/**
* Title
*
* The full name of the source.
* (Required)
*
*/
@JsonProperty("title")
public void setTitle(String title) {
this.title = title;
}
public Sources withTitle(String title) {
this.title = title;
return this;
}
/**
* Description
*
* The full description of the source.
*
*/
@JsonProperty("description")
public String getDescription() {
return description;
}
/**
* Description
*
* The full description of the source.
*
*/
@JsonProperty("description")
public void setDescription(String description) {
this.description = description;
}
public Sources withDescription(String description) {
this.description = description;
return this;
}
/**
* code
*
* The code of the source.
*
*/
@JsonProperty("code")
public String getCode() {
return code;
}
/**
* code
*
* The code of the source.
*
*/
@JsonProperty("code")
public void setCode(String code) {
this.code = code;
}
public Sources withCode(String code) {
this.code = code;
return this;
}
/**
* Context
*
* The context the source is used in.
*
*/
@JsonProperty("contexts")
public List getContexts() {
return contexts;
}
/**
* Context
*
* The context the source is used in.
*
*/
@JsonProperty("contexts")
public void setContexts(List contexts) {
this.contexts = contexts;
}
public Sources withContexts(List contexts) {
this.contexts = contexts;
return this;
}
/**
* Status
*
* The status of the source in this context.
* (Required)
*
*/
@JsonProperty("status")
public Sources.Status getStatus() {
return status;
}
/**
* Status
*
* The status of the source in this context.
* (Required)
*
*/
@JsonProperty("status")
public void setStatus(Sources.Status status) {
this.status = status;
}
public Sources withStatus(Sources.Status status) {
this.status = status;
return this;
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append(Sources.class.getName()).append('@').append(Integer.toHexString(System.identityHashCode(this))).append('[');
sb.append("metadata");
sb.append('=');
sb.append(((this.metadata == null)?"":this.metadata));
sb.append(',');
sb.append("id");
sb.append('=');
sb.append(((this.id == null)?"":this.id));
sb.append(',');
sb.append("title");
sb.append('=');
sb.append(((this.title == null)?"":this.title));
sb.append(',');
sb.append("description");
sb.append('=');
sb.append(((this.description == null)?"":this.description));
sb.append(',');
sb.append("code");
sb.append('=');
sb.append(((this.code == null)?"":this.code));
sb.append(',');
sb.append("contexts");
sb.append('=');
sb.append(((this.contexts == null)?"":this.contexts));
sb.append(',');
sb.append("status");
sb.append('=');
sb.append(((this.status == null)?"":this.status));
sb.append(',');
if (sb.charAt((sb.length()- 1)) == ',') {
sb.setCharAt((sb.length()- 1), ']');
} else {
sb.append(']');
}
return sb.toString();
}
@Override
public int hashCode() {
int result = 1;
result = ((result* 31)+((this.metadata == null)? 0 :this.metadata.hashCode()));
result = ((result* 31)+((this.code == null)? 0 :this.code.hashCode()));
result = ((result* 31)+((this.description == null)? 0 :this.description.hashCode()));
result = ((result* 31)+((this.id == null)? 0 :this.id.hashCode()));
result = ((result* 31)+((this.contexts == null)? 0 :this.contexts.hashCode()));
result = ((result* 31)+((this.title == null)? 0 :this.title.hashCode()));
result = ((result* 31)+((this.status == null)? 0 :this.status.hashCode()));
return result;
}
@Override
public boolean equals(Object other) {
if (other == this) {
return true;
}
if ((other instanceof Sources) == false) {
return false;
}
Sources rhs = ((Sources) other);
return ((((((((this.metadata == rhs.metadata)||((this.metadata!= null)&&this.metadata.equals(rhs.metadata)))&&((this.code == rhs.code)||((this.code!= null)&&this.code.equals(rhs.code))))&&((this.description == rhs.description)||((this.description!= null)&&this.description.equals(rhs.description))))&&((this.id == rhs.id)||((this.id!= null)&&this.id.equals(rhs.id))))&&((this.contexts == rhs.contexts)||((this.contexts!= null)&&this.contexts.equals(rhs.contexts))))&&((this.title == rhs.title)||((this.title!= null)&&this.title.equals(rhs.title))))&&((this.status == rhs.status)||((this.status!= null)&&this.status.equals(rhs.status))));
}
/**
* Status
*
* The status of the source in this context.
*
*/
@Generated("jsonschema2pojo")
public enum Status {
ACTIVE("active"),
INACTIVE("inactive");
private final String value;
private final static Map CONSTANTS = new HashMap();
static {
for (Sources.Status c: values()) {
CONSTANTS.put(c.value, c);
}
}
Status(String value) {
this.value = value;
}
@Override
public String toString() {
return this.value;
}
@JsonValue
public String value() {
return this.value;
}
@JsonCreator
public static Sources.Status fromValue(String value) {
Sources.Status constant = CONSTANTS.get(value);
if (constant == null) {
throw new IllegalArgumentException(value);
} else {
return constant;
}
}
}
}