Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
/**
* Autogenerated by Avro
*
* DO NOT EDIT DIRECTLY
*/
package org.gel.models.report.avro;
@SuppressWarnings("all")
@org.apache.avro.specific.AvroGenerated
public class Prognosis extends org.apache.avro.specific.SpecificRecordBase implements org.apache.avro.specific.SpecificRecord {
public static final org.apache.avro.Schema SCHEMA$ = new org.apache.avro.Schema.Parser().parse("{\"type\":\"record\",\"name\":\"Prognosis\",\"namespace\":\"org.gel.models.report.avro\",\"fields\":[{\"name\":\"referenceUrl\",\"type\":{\"type\":\"string\",\"avro.java.string\":\"String\"},\"doc\":\"URL where reference information for this prognosis can be found\"},{\"name\":\"prognosis\",\"type\":[\"null\",{\"type\":\"enum\",\"name\":\"PrognosisClassification\",\"symbols\":[\"altered_prognosis\",\"favourable_prognosis\",\"unfavourable_prognosis\"]}],\"doc\":\"Prognosis classification (defined as favourable or unfavourable),\\n in the case that the direction of the prognosis is not known altered_prognosis should be used\"},{\"name\":\"source\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"Source if known\"},{\"name\":\"references\",\"type\":[\"null\",{\"type\":\"array\",\"items\":{\"type\":\"string\",\"avro.java.string\":\"String\"}}],\"doc\":\"References\"},{\"name\":\"conditions\",\"type\":[\"null\",{\"type\":\"array\",\"items\":{\"type\":\"string\",\"avro.java.string\":\"String\"}}],\"doc\":\"Conditions\"},{\"name\":\"description\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"Full description of the associated prognosis\"},{\"name\":\"variantActionable\",\"type\":\"boolean\",\"doc\":\"If true, the association was made at the variant level, if not the association was made at Genomic Entity level\"}]}");
public static org.apache.avro.Schema getClassSchema() { return SCHEMA$; }
/** URL where reference information for this prognosis can be found */
private java.lang.String referenceUrl;
/** Prognosis classification (defined as favourable or unfavourable),
in the case that the direction of the prognosis is not known altered_prognosis should be used */
private org.gel.models.report.avro.PrognosisClassification prognosis;
/** Source if known */
private java.lang.String source;
/** References */
private java.util.List references;
/** Conditions */
private java.util.List conditions;
/** Full description of the associated prognosis */
private java.lang.String description;
/** If true, the association was made at the variant level, if not the association was made at Genomic Entity level */
private boolean variantActionable;
/**
* Default constructor. Note that this does not initialize fields
* to their default values from the schema. If that is desired then
* one should use newBuilder().
*/
public Prognosis() {}
/**
* All-args constructor.
*/
public Prognosis(java.lang.String referenceUrl, org.gel.models.report.avro.PrognosisClassification prognosis, java.lang.String source, java.util.List references, java.util.List conditions, java.lang.String description, java.lang.Boolean variantActionable) {
this.referenceUrl = referenceUrl;
this.prognosis = prognosis;
this.source = source;
this.references = references;
this.conditions = conditions;
this.description = description;
this.variantActionable = variantActionable;
}
public org.apache.avro.Schema getSchema() { return SCHEMA$; }
// Used by DatumWriter. Applications should not call.
public java.lang.Object get(int field$) {
switch (field$) {
case 0: return referenceUrl;
case 1: return prognosis;
case 2: return source;
case 3: return references;
case 4: return conditions;
case 5: return description;
case 6: return variantActionable;
default: throw new org.apache.avro.AvroRuntimeException("Bad index");
}
}
// Used by DatumReader. Applications should not call.
@SuppressWarnings(value="unchecked")
public void put(int field$, java.lang.Object value$) {
switch (field$) {
case 0: referenceUrl = (java.lang.String)value$; break;
case 1: prognosis = (org.gel.models.report.avro.PrognosisClassification)value$; break;
case 2: source = (java.lang.String)value$; break;
case 3: references = (java.util.List)value$; break;
case 4: conditions = (java.util.List)value$; break;
case 5: description = (java.lang.String)value$; break;
case 6: variantActionable = (java.lang.Boolean)value$; break;
default: throw new org.apache.avro.AvroRuntimeException("Bad index");
}
}
/**
* Gets the value of the 'referenceUrl' field.
* URL where reference information for this prognosis can be found */
public java.lang.String getReferenceUrl() {
return referenceUrl;
}
/**
* Sets the value of the 'referenceUrl' field.
* URL where reference information for this prognosis can be found * @param value the value to set.
*/
public void setReferenceUrl(java.lang.String value) {
this.referenceUrl = value;
}
/**
* Gets the value of the 'prognosis' field.
* Prognosis classification (defined as favourable or unfavourable),
in the case that the direction of the prognosis is not known altered_prognosis should be used */
public org.gel.models.report.avro.PrognosisClassification getPrognosis() {
return prognosis;
}
/**
* Sets the value of the 'prognosis' field.
* Prognosis classification (defined as favourable or unfavourable),
in the case that the direction of the prognosis is not known altered_prognosis should be used * @param value the value to set.
*/
public void setPrognosis(org.gel.models.report.avro.PrognosisClassification value) {
this.prognosis = value;
}
/**
* Gets the value of the 'source' field.
* Source if known */
public java.lang.String getSource() {
return source;
}
/**
* Sets the value of the 'source' field.
* Source if known * @param value the value to set.
*/
public void setSource(java.lang.String value) {
this.source = value;
}
/**
* Gets the value of the 'references' field.
* References */
public java.util.List getReferences() {
return references;
}
/**
* Sets the value of the 'references' field.
* References * @param value the value to set.
*/
public void setReferences(java.util.List value) {
this.references = value;
}
/**
* Gets the value of the 'conditions' field.
* Conditions */
public java.util.List getConditions() {
return conditions;
}
/**
* Sets the value of the 'conditions' field.
* Conditions * @param value the value to set.
*/
public void setConditions(java.util.List value) {
this.conditions = value;
}
/**
* Gets the value of the 'description' field.
* Full description of the associated prognosis */
public java.lang.String getDescription() {
return description;
}
/**
* Sets the value of the 'description' field.
* Full description of the associated prognosis * @param value the value to set.
*/
public void setDescription(java.lang.String value) {
this.description = value;
}
/**
* Gets the value of the 'variantActionable' field.
* If true, the association was made at the variant level, if not the association was made at Genomic Entity level */
public java.lang.Boolean getVariantActionable() {
return variantActionable;
}
/**
* Sets the value of the 'variantActionable' field.
* If true, the association was made at the variant level, if not the association was made at Genomic Entity level * @param value the value to set.
*/
public void setVariantActionable(java.lang.Boolean value) {
this.variantActionable = value;
}
/** Creates a new Prognosis RecordBuilder */
public static org.gel.models.report.avro.Prognosis.Builder newBuilder() {
return new org.gel.models.report.avro.Prognosis.Builder();
}
/** Creates a new Prognosis RecordBuilder by copying an existing Builder */
public static org.gel.models.report.avro.Prognosis.Builder newBuilder(org.gel.models.report.avro.Prognosis.Builder other) {
return new org.gel.models.report.avro.Prognosis.Builder(other);
}
/** Creates a new Prognosis RecordBuilder by copying an existing Prognosis instance */
public static org.gel.models.report.avro.Prognosis.Builder newBuilder(org.gel.models.report.avro.Prognosis other) {
return new org.gel.models.report.avro.Prognosis.Builder(other);
}
/**
* RecordBuilder for Prognosis instances.
*/
public static class Builder extends org.apache.avro.specific.SpecificRecordBuilderBase
implements org.apache.avro.data.RecordBuilder {
private java.lang.String referenceUrl;
private org.gel.models.report.avro.PrognosisClassification prognosis;
private java.lang.String source;
private java.util.List references;
private java.util.List conditions;
private java.lang.String description;
private boolean variantActionable;
/** Creates a new Builder */
private Builder() {
super(org.gel.models.report.avro.Prognosis.SCHEMA$);
}
/** Creates a Builder by copying an existing Builder */
private Builder(org.gel.models.report.avro.Prognosis.Builder other) {
super(other);
if (isValidValue(fields()[0], other.referenceUrl)) {
this.referenceUrl = data().deepCopy(fields()[0].schema(), other.referenceUrl);
fieldSetFlags()[0] = true;
}
if (isValidValue(fields()[1], other.prognosis)) {
this.prognosis = data().deepCopy(fields()[1].schema(), other.prognosis);
fieldSetFlags()[1] = true;
}
if (isValidValue(fields()[2], other.source)) {
this.source = data().deepCopy(fields()[2].schema(), other.source);
fieldSetFlags()[2] = true;
}
if (isValidValue(fields()[3], other.references)) {
this.references = data().deepCopy(fields()[3].schema(), other.references);
fieldSetFlags()[3] = true;
}
if (isValidValue(fields()[4], other.conditions)) {
this.conditions = data().deepCopy(fields()[4].schema(), other.conditions);
fieldSetFlags()[4] = true;
}
if (isValidValue(fields()[5], other.description)) {
this.description = data().deepCopy(fields()[5].schema(), other.description);
fieldSetFlags()[5] = true;
}
if (isValidValue(fields()[6], other.variantActionable)) {
this.variantActionable = data().deepCopy(fields()[6].schema(), other.variantActionable);
fieldSetFlags()[6] = true;
}
}
/** Creates a Builder by copying an existing Prognosis instance */
private Builder(org.gel.models.report.avro.Prognosis other) {
super(org.gel.models.report.avro.Prognosis.SCHEMA$);
if (isValidValue(fields()[0], other.referenceUrl)) {
this.referenceUrl = data().deepCopy(fields()[0].schema(), other.referenceUrl);
fieldSetFlags()[0] = true;
}
if (isValidValue(fields()[1], other.prognosis)) {
this.prognosis = data().deepCopy(fields()[1].schema(), other.prognosis);
fieldSetFlags()[1] = true;
}
if (isValidValue(fields()[2], other.source)) {
this.source = data().deepCopy(fields()[2].schema(), other.source);
fieldSetFlags()[2] = true;
}
if (isValidValue(fields()[3], other.references)) {
this.references = data().deepCopy(fields()[3].schema(), other.references);
fieldSetFlags()[3] = true;
}
if (isValidValue(fields()[4], other.conditions)) {
this.conditions = data().deepCopy(fields()[4].schema(), other.conditions);
fieldSetFlags()[4] = true;
}
if (isValidValue(fields()[5], other.description)) {
this.description = data().deepCopy(fields()[5].schema(), other.description);
fieldSetFlags()[5] = true;
}
if (isValidValue(fields()[6], other.variantActionable)) {
this.variantActionable = data().deepCopy(fields()[6].schema(), other.variantActionable);
fieldSetFlags()[6] = true;
}
}
/** Gets the value of the 'referenceUrl' field */
public java.lang.String getReferenceUrl() {
return referenceUrl;
}
/** Sets the value of the 'referenceUrl' field */
public org.gel.models.report.avro.Prognosis.Builder setReferenceUrl(java.lang.String value) {
validate(fields()[0], value);
this.referenceUrl = value;
fieldSetFlags()[0] = true;
return this;
}
/** Checks whether the 'referenceUrl' field has been set */
public boolean hasReferenceUrl() {
return fieldSetFlags()[0];
}
/** Clears the value of the 'referenceUrl' field */
public org.gel.models.report.avro.Prognosis.Builder clearReferenceUrl() {
referenceUrl = null;
fieldSetFlags()[0] = false;
return this;
}
/** Gets the value of the 'prognosis' field */
public org.gel.models.report.avro.PrognosisClassification getPrognosis() {
return prognosis;
}
/** Sets the value of the 'prognosis' field */
public org.gel.models.report.avro.Prognosis.Builder setPrognosis(org.gel.models.report.avro.PrognosisClassification value) {
validate(fields()[1], value);
this.prognosis = value;
fieldSetFlags()[1] = true;
return this;
}
/** Checks whether the 'prognosis' field has been set */
public boolean hasPrognosis() {
return fieldSetFlags()[1];
}
/** Clears the value of the 'prognosis' field */
public org.gel.models.report.avro.Prognosis.Builder clearPrognosis() {
prognosis = null;
fieldSetFlags()[1] = false;
return this;
}
/** Gets the value of the 'source' field */
public java.lang.String getSource() {
return source;
}
/** Sets the value of the 'source' field */
public org.gel.models.report.avro.Prognosis.Builder setSource(java.lang.String value) {
validate(fields()[2], value);
this.source = value;
fieldSetFlags()[2] = true;
return this;
}
/** Checks whether the 'source' field has been set */
public boolean hasSource() {
return fieldSetFlags()[2];
}
/** Clears the value of the 'source' field */
public org.gel.models.report.avro.Prognosis.Builder clearSource() {
source = null;
fieldSetFlags()[2] = false;
return this;
}
/** Gets the value of the 'references' field */
public java.util.List getReferences() {
return references;
}
/** Sets the value of the 'references' field */
public org.gel.models.report.avro.Prognosis.Builder setReferences(java.util.List value) {
validate(fields()[3], value);
this.references = value;
fieldSetFlags()[3] = true;
return this;
}
/** Checks whether the 'references' field has been set */
public boolean hasReferences() {
return fieldSetFlags()[3];
}
/** Clears the value of the 'references' field */
public org.gel.models.report.avro.Prognosis.Builder clearReferences() {
references = null;
fieldSetFlags()[3] = false;
return this;
}
/** Gets the value of the 'conditions' field */
public java.util.List getConditions() {
return conditions;
}
/** Sets the value of the 'conditions' field */
public org.gel.models.report.avro.Prognosis.Builder setConditions(java.util.List value) {
validate(fields()[4], value);
this.conditions = value;
fieldSetFlags()[4] = true;
return this;
}
/** Checks whether the 'conditions' field has been set */
public boolean hasConditions() {
return fieldSetFlags()[4];
}
/** Clears the value of the 'conditions' field */
public org.gel.models.report.avro.Prognosis.Builder clearConditions() {
conditions = null;
fieldSetFlags()[4] = false;
return this;
}
/** Gets the value of the 'description' field */
public java.lang.String getDescription() {
return description;
}
/** Sets the value of the 'description' field */
public org.gel.models.report.avro.Prognosis.Builder setDescription(java.lang.String value) {
validate(fields()[5], value);
this.description = value;
fieldSetFlags()[5] = true;
return this;
}
/** Checks whether the 'description' field has been set */
public boolean hasDescription() {
return fieldSetFlags()[5];
}
/** Clears the value of the 'description' field */
public org.gel.models.report.avro.Prognosis.Builder clearDescription() {
description = null;
fieldSetFlags()[5] = false;
return this;
}
/** Gets the value of the 'variantActionable' field */
public java.lang.Boolean getVariantActionable() {
return variantActionable;
}
/** Sets the value of the 'variantActionable' field */
public org.gel.models.report.avro.Prognosis.Builder setVariantActionable(boolean value) {
validate(fields()[6], value);
this.variantActionable = value;
fieldSetFlags()[6] = true;
return this;
}
/** Checks whether the 'variantActionable' field has been set */
public boolean hasVariantActionable() {
return fieldSetFlags()[6];
}
/** Clears the value of the 'variantActionable' field */
public org.gel.models.report.avro.Prognosis.Builder clearVariantActionable() {
fieldSetFlags()[6] = false;
return this;
}
@Override
public Prognosis build() {
try {
Prognosis record = new Prognosis();
record.referenceUrl = fieldSetFlags()[0] ? this.referenceUrl : (java.lang.String) defaultValue(fields()[0]);
record.prognosis = fieldSetFlags()[1] ? this.prognosis : (org.gel.models.report.avro.PrognosisClassification) defaultValue(fields()[1]);
record.source = fieldSetFlags()[2] ? this.source : (java.lang.String) defaultValue(fields()[2]);
record.references = fieldSetFlags()[3] ? this.references : (java.util.List) defaultValue(fields()[3]);
record.conditions = fieldSetFlags()[4] ? this.conditions : (java.util.List) defaultValue(fields()[4]);
record.description = fieldSetFlags()[5] ? this.description : (java.lang.String) defaultValue(fields()[5]);
record.variantActionable = fieldSetFlags()[6] ? this.variantActionable : (java.lang.Boolean) defaultValue(fields()[6]);
return record;
} catch (Exception e) {
throw new org.apache.avro.AvroRuntimeException(e);
}
}
}
}