if (isValidValue(fields()[0], other.mutationId)) { this.mutationId = data().deepCopy(fields()[0].schema(), other.mutationId); fieldSetFlags()[0] = true; if (isValidValue(fields()[1], other.primarySite)) { this.primarySite = data().deepCopy(fields()[1].schema(), other.primarySite); fieldSetFlags()[1] = true; if (isValidValue(fields()[2], other.siteSubtype)) { this.siteSubtype = data().deepCopy(fields()[2].schema(), other.siteSubtype); fieldSetFlags()[2] = true; if (isValidValue(fields()[3], other.primaryHistology)) { this.primaryHistology = data().deepCopy(fields()[3].schema(), other.primaryHistology); fieldSetFlags()[3] = true; if (isValidValue(fields()[4], other.histologySubtype)) { this.histologySubtype = data().deepCopy(fields()[4].schema(), other.histologySubtype); fieldSetFlags()[4] = true; if (isValidValue(fields()[5], other.sampleSource)) { this.sampleSource = data().deepCopy(fields()[5].schema(), other.sampleSource); fieldSetFlags()[5] = true; if (isValidValue(fields()[6], other.tumourOrigin)) { this.tumourOrigin = data().deepCopy(fields()[6].schema(), other.tumourOrigin); fieldSetFlags()[6] = true; if (isValidValue(fields()[7], other.geneName)) {
@Override public Cosmic build() { try { Cosmic record = new Cosmic(); record.mutationId = fieldSetFlags()[0] ? this.mutationId : (java.lang.String) defaultValue(fields()[0]); record.primarySite = fieldSetFlags()[1] ? this.primarySite : (java.lang.String) defaultValue(fields()[1]); record.siteSubtype = fieldSetFlags()[2] ? this.siteSubtype : (java.lang.String) defaultValue(fields()[2]); record.primaryHistology = fieldSetFlags()[3] ? this.primaryHistology : (java.lang.String) defaultValue(fields()[3]); record.histologySubtype = fieldSetFlags()[4] ? this.histologySubtype : (java.lang.String) defaultValue(fields()[4]); record.sampleSource = fieldSetFlags()[5] ? this.sampleSource : (java.lang.String) defaultValue(fields()[5]); record.tumourOrigin = fieldSetFlags()[6] ? this.tumourOrigin : (java.lang.String) defaultValue(fields()[6]); record.geneName = fieldSetFlags()[7] ? this.geneName : (java.lang.String) defaultValue(fields()[7]); record.mutationSomaticStatus = fieldSetFlags()[8] ? this.mutationSomaticStatus : (java.lang.String) defaultValue(fields()[8]); return record; } catch (Exception e) { throw new org.apache.avro.AvroRuntimeException(e); } } }
if (isValidValue(fields()[0], other.mutationId)) { this.mutationId = data().deepCopy(fields()[0].schema(), other.mutationId); fieldSetFlags()[0] = true; if (isValidValue(fields()[1], other.primarySite)) { this.primarySite = data().deepCopy(fields()[1].schema(), other.primarySite); fieldSetFlags()[1] = true; if (isValidValue(fields()[2], other.siteSubtype)) { this.siteSubtype = data().deepCopy(fields()[2].schema(), other.siteSubtype); fieldSetFlags()[2] = true; if (isValidValue(fields()[3], other.primaryHistology)) { this.primaryHistology = data().deepCopy(fields()[3].schema(), other.primaryHistology); fieldSetFlags()[3] = true; if (isValidValue(fields()[4], other.histologySubtype)) { this.histologySubtype = data().deepCopy(fields()[4].schema(), other.histologySubtype); fieldSetFlags()[4] = true; if (isValidValue(fields()[5], other.sampleSource)) { this.sampleSource = data().deepCopy(fields()[5].schema(), other.sampleSource); fieldSetFlags()[5] = true; if (isValidValue(fields()[6], other.tumourOrigin)) { this.tumourOrigin = data().deepCopy(fields()[6].schema(), other.tumourOrigin); fieldSetFlags()[6] = true; if (isValidValue(fields()[7], other.geneName)) {
/** Checks whether the 'geneName' field has been set */ public boolean hasGeneName() { return fieldSetFlags()[7]; }
/** Checks whether the 'primaryHistology' field has been set */ public boolean hasPrimaryHistology() { return fieldSetFlags()[3]; }
/** Checks whether the 'siteSubtype' field has been set */ public boolean hasSiteSubtype() { return fieldSetFlags()[2]; }
/** Creates a new Cosmic RecordBuilder */ public static org.opencb.biodata.models.variant.avro.Cosmic.Builder newBuilder() { return new org.opencb.biodata.models.variant.avro.Cosmic.Builder(); }
/** Checks whether the 'tumourOrigin' field has been set */ public boolean hasTumourOrigin() { return fieldSetFlags()[6]; }
/** Checks whether the 'sampleSource' field has been set */ public boolean hasSampleSource() { return fieldSetFlags()[5]; }
/** Creates a new Cosmic RecordBuilder by copying an existing Cosmic instance */ public static org.opencb.biodata.models.variant.avro.Cosmic.Builder newBuilder(org.opencb.biodata.models.variant.avro.Cosmic other) { return new org.opencb.biodata.models.variant.avro.Cosmic.Builder(other); }
/** Clears the value of the 'sampleSource' field */ public org.opencb.biodata.models.variant.avro.Cosmic.Builder clearSampleSource() { sampleSource = null; fieldSetFlags()[5] = false; return this; }
/** Clears the value of the 'histologySubtype' field */ public org.opencb.biodata.models.variant.avro.Cosmic.Builder clearHistologySubtype() { histologySubtype = null; fieldSetFlags()[4] = false; return this; }
/** Clears the value of the 'mutationId' field */ public org.opencb.biodata.models.variant.avro.Cosmic.Builder clearMutationId() { mutationId = null; fieldSetFlags()[0] = false; return this; }
/** Checks whether the 'mutationSomaticStatus' field has been set */ public boolean hasMutationSomaticStatus() { return fieldSetFlags()[8]; }
/** Checks whether the 'histologySubtype' field has been set */ public boolean hasHistologySubtype() { return fieldSetFlags()[4]; }
/** Checks whether the 'primarySite' field has been set */ public boolean hasPrimarySite() { return fieldSetFlags()[1]; }
/** Creates a new Cosmic RecordBuilder by copying an existing Builder */ public static org.opencb.biodata.models.variant.avro.Cosmic.Builder newBuilder(org.opencb.biodata.models.variant.avro.Cosmic.Builder other) { return new org.opencb.biodata.models.variant.avro.Cosmic.Builder(other); }
/** Clears the value of the 'primaryHistology' field */ public org.opencb.biodata.models.variant.avro.Cosmic.Builder clearPrimaryHistology() { primaryHistology = null; fieldSetFlags()[3] = false; return this; }
/** Sets the value of the 'mutationSomaticStatus' field */ public org.opencb.biodata.models.variant.avro.Cosmic.Builder setMutationSomaticStatus(java.lang.String value) { validate(fields()[8], value); this.mutationSomaticStatus = value; fieldSetFlags()[8] = true; return this; }
/** Sets the value of the 'primarySite' field */ public org.opencb.biodata.models.variant.avro.Cosmic.Builder setPrimarySite(java.lang.String value) { validate(fields()[1], value); this.primarySite = value; fieldSetFlags()[1] = true; return this; }