no.ks.fiks.innsyn.schema.ekstern.domain.Forelder Maven / Gradle / Ivy
Show all versions of innsyn-json-schema Show documentation
package no.ks.fiks.innsyn.schema.ekstern.domain;
import java.util.HashMap;
import java.util.Map;
import java.util.UUID;
import javax.annotation.processing.Generated;
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;
/**
* Innsyn Forelder
*
* Definerer en annen indeksert melding som forelder til denne meldingen
*
*/
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonPropertyOrder({
"meldingId",
"type"
})
@Generated("jsonschema2pojo")
public class Forelder {
/**
* Spesifiser et foreldre-dokument
* (Required)
*
*/
@JsonProperty("meldingId")
@JsonPropertyDescription("Spesifiser et foreldre-dokument")
private UUID meldingId;
/**
* Innsyn Meldingstype
*
*
* (Required)
*
*/
@JsonProperty("type")
private Forelder.Meldingtype type;
/**
* Spesifiser et foreldre-dokument
* (Required)
*
*/
@JsonProperty("meldingId")
public UUID getMeldingId() {
return meldingId;
}
/**
* Spesifiser et foreldre-dokument
* (Required)
*
*/
@JsonProperty("meldingId")
public void setMeldingId(UUID meldingId) {
this.meldingId = meldingId;
}
public Forelder withMeldingId(UUID meldingId) {
this.meldingId = meldingId;
return this;
}
/**
* Innsyn Meldingstype
*
*
* (Required)
*
*/
@JsonProperty("type")
public Forelder.Meldingtype getType() {
return type;
}
/**
* Innsyn Meldingstype
*
*
* (Required)
*
*/
@JsonProperty("type")
public void setType(Forelder.Meldingtype type) {
this.type = type;
}
public Forelder withType(Forelder.Meldingtype type) {
this.type = type;
return this;
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append(Forelder.class.getName()).append('@').append(Integer.toHexString(System.identityHashCode(this))).append('[');
sb.append("meldingId");
sb.append('=');
sb.append(((this.meldingId == null)?"":this.meldingId));
sb.append(',');
sb.append("type");
sb.append('=');
sb.append(((this.type == null)?"":this.type));
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.type == null)? 0 :this.type.hashCode()));
result = ((result* 31)+((this.meldingId == null)? 0 :this.meldingId.hashCode()));
return result;
}
@Override
public boolean equals(Object other) {
if (other == this) {
return true;
}
if ((other instanceof Forelder) == false) {
return false;
}
Forelder rhs = ((Forelder) other);
return (((this.type == rhs.type)||((this.type!= null)&&this.type.equals(rhs.type)))&&((this.meldingId == rhs.meldingId)||((this.meldingId!= null)&&this.meldingId.equals(rhs.meldingId))));
}
/**
* Innsyn Meldingstype
*
*
*
*/
@Generated("jsonschema2pojo")
public enum Meldingtype {
FAKTURA("faktura"),
MAPPE("mappe"),
JOURNALPOST("journalpost"),
INNSENDTSKJEMA("innsendtskjema"),
SKJEMAKLADD("skjemakladd");
private final String value;
private final static Map CONSTANTS = new HashMap();
static {
for (Forelder.Meldingtype c: values()) {
CONSTANTS.put(c.value, c);
}
}
Meldingtype(String value) {
this.value = value;
}
@Override
public String toString() {
return this.value;
}
@JsonValue
public String value() {
return this.value;
}
@JsonCreator
public static Forelder.Meldingtype fromValue(String value) {
Forelder.Meldingtype constant = CONSTANTS.get(value);
if (constant == null) {
throw new IllegalArgumentException(value);
} else {
return constant;
}
}
}
}