All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.gel.models.participant.avro.CancerParticipant Maven / Gradle / Ivy

/**
 * Autogenerated by Avro
 * 
 * DO NOT EDIT DIRECTLY
 */
package org.gel.models.participant.avro;  
@SuppressWarnings("all")
/** This defines a Cancer Participant */
@org.apache.avro.specific.AvroGenerated
public class CancerParticipant 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\":\"CancerParticipant\",\"namespace\":\"org.gel.models.participant.avro\",\"doc\":\"This defines a Cancer Participant\",\"fields\":[{\"name\":\"yearOfBirth\",\"type\":[\"null\",\"int\"],\"doc\":\"Year of birth for the cancer participant\"},{\"name\":\"morphology\",\"type\":[\"null\",{\"type\":\"array\",\"items\":{\"type\":\"string\",\"avro.java.string\":\"String\"}}],\"doc\":\"Morphology of any tumours\\n        NOTE: In GMS, this field is deprecated as morphology will be in sample or with respect to a tumour record\"},{\"name\":\"readyForAnalysis\",\"type\":\"boolean\",\"doc\":\"Flag indicating if the participant is ready for analysis\\n        NOTE: In GMS, this will default to true\"},{\"name\":\"consentStatus\",\"type\":[\"null\",{\"type\":\"record\",\"name\":\"ConsentStatus\",\"doc\":\"Consent Status for 100k program\",\"fields\":[{\"name\":\"programmeConsent\",\"type\":\"boolean\",\"doc\":\"Is this individual consented to the programme?\\n        It could simply be a family member that is not consented but for whom affection status is known\",\"default\":false},{\"name\":\"primaryFindingConsent\",\"type\":\"boolean\",\"doc\":\"Consent for feedback of primary findings?\",\"default\":false},{\"name\":\"secondaryFindingConsent\",\"type\":\"boolean\",\"doc\":\"Consent for secondary finding lookup\",\"default\":false},{\"name\":\"carrierStatusConsent\",\"type\":\"boolean\",\"doc\":\"Consent for carrier status check?\",\"default\":false}]}],\"doc\":\"What has this participant consented to?\\n        A participant that has been consented to the programme should also have sequence data associated with them; however\\n        this needs to be programmatically checked\"},{\"name\":\"testConsentStatus\",\"type\":[\"null\",{\"type\":\"record\",\"name\":\"GmsConsentStatus\",\"doc\":\"Consent Status for GMS\",\"fields\":[{\"name\":\"programmeConsent\",\"type\":{\"type\":\"enum\",\"name\":\"GenericConsent\",\"doc\":\"clinicalEthnicities supersedes Ancestries in GMS\",\"symbols\":[\"yes\",\"no\",\"undefined\",\"not_applicable\"]},\"doc\":\"Is this individual consented to the programme? It could simply be a family member that is not consented\\n        but for whom affection status is known\"},{\"name\":\"primaryFindingConsent\",\"type\":\"GenericConsent\",\"doc\":\"Consent for feedback of primary findings?\\n        RD: Primary Findings\\n        Cancer: PrimaryFindings is somatic + pertinent germline findings\"},{\"name\":\"researchConsent\",\"type\":\"GenericConsent\",\"doc\":\"Research Consent\"},{\"name\":\"healthRelatedFindingConsent\",\"type\":\"GenericConsent\",\"doc\":\"Consent for secondary health related findings?\"},{\"name\":\"carrierStatusConsent\",\"type\":\"GenericConsent\",\"doc\":\"Consent for carrier status check?\"},{\"name\":\"pharmacogenomicsFindingConsent\",\"type\":\"GenericConsent\",\"doc\":\"Consent for pharmacogenomics consent as secondary findings?\"}]}],\"doc\":\"What has this participant consented in the context of a Genomic Test?\"},{\"name\":\"center\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"Center\\n        NOTE: In GMS, this will be taken from the ReferralTest and duplicated here\"},{\"name\":\"individualId\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"Individual identifier\"},{\"name\":\"participantId\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"This is a human readable participant ID\"},{\"name\":\"primaryDiagnosisDisease\",\"type\":[\"null\",{\"type\":\"array\",\"items\":{\"type\":\"string\",\"avro.java.string\":\"String\"}}],\"doc\":\"This should be an enumeration when it is well defined\\n        blood, breast, prostate, colorectal, cll, aml, renal, ovarian, skin, lymphNode, bone, saliva //for individual - there could be more than I have listed here, in fact there definitely will.\\n        In GMS, this field is deprecated\"},{\"name\":\"primaryDiagnosisSubDisease\",\"type\":[\"null\",{\"type\":\"array\",\"items\":{\"type\":\"string\",\"avro.java.string\":\"String\"}}],\"doc\":\"This should be an enumeration when it is well defined\\n        blood, breast, prostate, colorectal, cll, aml, renal, ovarian, skin, lymphNode, bone, saliva //for individual - there could be more than I have listed here, in fact there definitely will.\\n        In GMS, this field is deprecated\"},{\"name\":\"sex\",\"type\":{\"type\":\"enum\",\"name\":\"Sex\",\"doc\":\"Sex\",\"symbols\":[\"MALE\",\"FEMALE\",\"UNKNOWN\"]},\"doc\":\"Sex\"},{\"name\":\"additionalInformation\",\"type\":[\"null\",{\"type\":\"map\",\"values\":{\"type\":\"string\",\"avro.java.string\":\"String\"},\"avro.java.string\":\"String\"}],\"doc\":\"We could add a map here to store additional information for example URIs to images, ECGs, etc\"},{\"name\":\"assignedICD10\",\"type\":[\"null\",{\"type\":\"array\",\"items\":{\"type\":\"string\",\"avro.java.string\":\"String\"}}],\"doc\":\"assigned ICD10 code\\n        IN GMS, this is deprecated\"},{\"name\":\"tumourSamples\",\"type\":[\"null\",{\"type\":\"array\",\"items\":{\"type\":\"record\",\"name\":\"TumourSample\",\"doc\":\"A tumour sample\",\"fields\":[{\"name\":\"sampleId\",\"type\":{\"type\":\"string\",\"avro.java.string\":\"String\"},\"doc\":\"Sample identifier (e.g, LP00012645_5GH))\"},{\"name\":\"labSampleId\",\"type\":{\"type\":\"string\",\"avro.java.string\":\"String\"},\"doc\":\"Lab sample identifier\"},{\"name\":\"LDPCode\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"LDP Code (Local Delivery Partner)\"},{\"name\":\"tumourId\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"This is the ID of the tumour from which this tumour sample was taken from\"},{\"name\":\"programmePhase\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"Genomics England programme phase\"},{\"name\":\"diseaseType\",\"type\":[\"null\",{\"type\":\"enum\",\"name\":\"diseaseType\",\"symbols\":[\"ADULT_GLIOMA\",\"BLADDER\",\"BREAST\",\"CARCINOMA_OF_UNKNOWN_PRIMARY\",\"CHILDHOOD\",\"COLORECTAL\",\"ENDOCRINE\",\"ENDOMETRIAL_CARCINOMA\",\"HAEMONC\",\"HEPATOPANCREATOBILIARY\",\"LUNG\",\"MALIGNANT_MELANOMA\",\"NASOPHARYNGEAL\",\"ORAL_OROPHARYNGEAL\",\"OVARIAN\",\"PROSTATE\",\"RENAL\",\"SARCOMA\",\"SINONASAL\",\"TESTICULAR_GERM_CELL_TUMOURS\",\"UPPER_GASTROINTESTINAL\",\"OTHER\",\"NON_HODGKINS_B_CELL_LYMPHOMA_LOW_MOD_GRADE\",\"CLASSICAL_HODGKINS\",\"NODULAR_LYMPHOCYTE_PREDOMINANT_HODGKINS\",\"T_CELL_LYMPHOMA\"]}],\"doc\":\"Disease type.\\n        NOTE: Deprecated in GMS\"},{\"name\":\"diseaseSubType\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"Disease subtype.\\n        NOTE: Deprecated in GMS\"},{\"name\":\"haematologicalCancer\",\"type\":[\"null\",\"boolean\"],\"doc\":\"True or false if this sample is of type: Haematological Cancer\"},{\"name\":\"haematologicalCancerLineage\",\"type\":[\"null\",{\"type\":\"enum\",\"name\":\"HaematologicalCancerLineage\",\"symbols\":[\"MYELOID\",\"LYMPHOID\",\"UNKNOWN\"]}],\"doc\":\"This is the Haematological cancer lineage of the tumourSample if this sample is from a haematological cancer\"},{\"name\":\"clinicalSampleDateTime\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"The time when the sample was received. In the format YYYY-MM-DDTHH:MM:SS+0000\"},{\"name\":\"tumourType\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"Tumor type.\\n        NOTE: Deprecated in GMS in tumourSample but available in tumour record\"},{\"name\":\"tumourContent\",\"type\":[\"null\",{\"type\":\"enum\",\"name\":\"TumourContent\",\"symbols\":[\"High\",\"Medium\",\"Low\"]}],\"doc\":\"This is the tumour content\"},{\"name\":\"tumourContentPercentage\",\"type\":[\"null\",\"float\"],\"doc\":\"This is the tumour content percentage\"},{\"name\":\"source\",\"type\":[\"null\",{\"type\":\"enum\",\"name\":\"SampleSource\",\"doc\":\"The source of the sample\\n    NOTE: IN GMS, BONE_MARROW_ASPIRATE_TUMOUR_CELLS and BONE_MARROW_ASPIRATE_TUMOUR_SORTED_CELLS are deprecated as they have been separated into their respective biotypes\",\"symbols\":[\"AMNIOTIC_FLUID\",\"BLOOD\",\"BONE_MARROW\",\"BONE_MARROW_ASPIRATE_TUMOUR_CELLS\",\"BONE_MARROW_ASPIRATE_TUMOUR_SORTED_CELLS\",\"BUCCAL_SWAB\",\"CHORIONIC_VILLUS_SAMPLE\",\"FIBROBLAST\",\"FLUID\",\"FRESH_TISSUE_IN_CULTURE_MEDIUM\",\"OTHER\",\"SALIVA\",\"TISSUE\",\"TUMOUR\",\"URINE\"]}],\"doc\":\"Source of the sample\"},{\"name\":\"preparationMethod\",\"type\":[\"null\",{\"type\":\"enum\",\"name\":\"PreparationMethod\",\"doc\":\"In 100K, preparation Method of sample\\n    NOTE: In GMS, this field is deprecated in favour of StorageMedium and Method\",\"symbols\":[\"ASPIRATE\",\"CD128_SORTED_CELLS\",\"CD138_SORTED_CELLS\",\"EDTA\",\"FF\",\"FFPE\",\"LI_HEP\",\"ORAGENE\"]}],\"doc\":\"The preparation method of the sample\\n        NOTE: Deprecated in GMS in replace of Method and storageMedium record\"},{\"name\":\"tissueSource\",\"type\":[\"null\",{\"type\":\"s","tring\",\"avro.java.string\":\"String\"}],\"doc\":\"The tissue source of the sample.\\n        NOTE: DEPRECATED IN GMS in replace of method record\"},{\"name\":\"product\",\"type\":[\"null\",{\"type\":\"enum\",\"name\":\"Product\",\"symbols\":[\"DNA\",\"RNA\"]}],\"doc\":\"Product of the sample\"},{\"name\":\"sampleMorphologies\",\"type\":[\"null\",{\"type\":\"array\",\"items\":{\"type\":\"record\",\"name\":\"Morphology\",\"fields\":[{\"name\":\"id\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"The ontology term id or accession in OBO format ${ONTOLOGY_ID}:${TERM_ID} (http://www.obofoundry.org/id-policy.html)\"},{\"name\":\"name\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"The ontology term name\"},{\"name\":\"value\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"Optional value for the ontology term, the type of the value is not checked\\n        (i.e.: we could set the pvalue term to \\\"significant\\\" or to \\\"0.0001\\\")\"},{\"name\":\"version\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"Ontology version\"}]}}],\"doc\":\"Morphology according to the sample taken\"},{\"name\":\"sampleTopographies\",\"type\":[\"null\",{\"type\":\"array\",\"items\":{\"type\":\"record\",\"name\":\"Topography\",\"fields\":[{\"name\":\"id\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"The ontology term id or accession in OBO format ${ONTOLOGY_ID}:${TERM_ID} (http://www.obofoundry.org/id-policy.html)\"},{\"name\":\"name\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"The ontology term name\"},{\"name\":\"value\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"Optional value for the ontology term, the type of the value is not checked\\n        (i.e.: we could set the pvalue term to \\\"significant\\\" or to \\\"0.0001\\\")\"},{\"name\":\"version\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"Ontology version\"}]}}],\"doc\":\"Topography according to the sample taken\"},{\"name\":\"sampleUid\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"In GMS, this is the GUID of the sample\"},{\"name\":\"participantId\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"Participant Id of the sample\"},{\"name\":\"participantUid\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"Participant UId of the sample\"},{\"name\":\"maskedPid\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"In GMS, this is the maskedPID\"},{\"name\":\"method\",\"type\":[\"null\",{\"type\":\"enum\",\"name\":\"Method\",\"doc\":\"In GMS, Method is defined as how the sample was taken directly from the patient\",\"symbols\":[\"ASPIRATE\",\"BIOPSY\",\"NOT_APPLICABLE\",\"RESECTION\",\"SORTED_OTHER\",\"UNKNOWN\",\"UNSORTED\",\"CD138_SORTED\"]}],\"doc\":\"In GMS, this is how the sample was extracted from the participant\"},{\"name\":\"storageMedium\",\"type\":[\"null\",{\"type\":\"enum\",\"name\":\"StorageMedium\",\"doc\":\"In GMS, storage medium of sample\",\"symbols\":[\"EDTA\",\"FF\",\"LI_HEP\",\"ORAGENE\",\"FFPE\"]}],\"doc\":\"In GMS, this is what solvent/medium the sample was stored in\"},{\"name\":\"sampleType\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"In GMS, this is the sampleType as entered by the clinician in TOMs\"},{\"name\":\"sampleState\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"In GMS, this is the sampleState as entered by the clinician in TOMs\"}]}}],\"doc\":\"List of tumour samples\\n        IN GMS, this is deprecated and moved to ReferralTest\"},{\"name\":\"germlineSamples\",\"type\":[\"null\",{\"type\":\"array\",\"items\":{\"type\":\"record\",\"name\":\"GermlineSample\",\"doc\":\"A germline sample\",\"fields\":[{\"name\":\"sampleId\",\"type\":{\"type\":\"string\",\"avro.java.string\":\"String\"},\"doc\":\"Sample identifier (e.g, LP00012645_5GH))\"},{\"name\":\"labSampleId\",\"type\":{\"type\":\"string\",\"avro.java.string\":\"String\"},\"doc\":\"Lab sample identifier\"},{\"name\":\"LDPCode\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"LDP Code (Local Delivery Partner)\"},{\"name\":\"source\",\"type\":[\"null\",\"SampleSource\"],\"doc\":\"Source of the sample\"},{\"name\":\"product\",\"type\":[\"null\",\"Product\"],\"doc\":\"Product of the sample\"},{\"name\":\"preparationMethod\",\"type\":[\"null\",\"PreparationMethod\"],\"doc\":\"Preparation method\\n        NOTE: In GMS, this has been deprecated in favour of Method and storageMedium\"},{\"name\":\"programmePhase\",\"type\":[\"null\",{\"type\":\"enum\",\"name\":\"ProgrammePhase\",\"symbols\":[\"CRUK\",\"OXFORD\",\"CLL\",\"IIP\",\"MAIN\",\"EXPT\"]}],\"doc\":\"Genomics England programme phase\"},{\"name\":\"clinicalSampleDateTime\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"The time when the sample was received. In the format YYYY-MM-DDTHH:MM:SS+0000\"},{\"name\":\"participantId\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}]},{\"name\":\"participantUid\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"Participant UId of the sample\"},{\"name\":\"sampleUid\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}]},{\"name\":\"maskedPid\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}]},{\"name\":\"method\",\"type\":[\"null\",\"Method\"],\"doc\":\"In GMS, this is how the sample was extracted from the participant\"},{\"name\":\"storageMedium\",\"type\":[\"null\",\"StorageMedium\"],\"doc\":\"In GMS, this is what solvent/medium the sample was stored in\"},{\"name\":\"sampleType\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"In GMS, this is the sampleType as entered by the clinician in TOMs\"},{\"name\":\"sampleState\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"In GMS, this is the sampleState as entered by the clinician in TOMs\"}]}}],\"doc\":\"List of germline samples\\n        IN GMS, this is deprecated and moved to ReferralTest\"},{\"name\":\"versionControl\",\"type\":[\"null\",{\"type\":\"record\",\"name\":\"VersionControl\",\"fields\":[{\"name\":\"GitVersionControl\",\"type\":{\"type\":\"string\",\"avro.java.string\":\"String\"},\"doc\":\"This is the version for the entire set of data models as referred to the Git release tag\",\"default\":\"1.3.0\"}]}],\"doc\":\"Model version number\"},{\"name\":\"participantUid\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"Individual UID in GMS\"},{\"name\":\"tumours\",\"type\":[\"null\",{\"type\":\"array\",\"items\":{\"type\":\"record\",\"name\":\"Tumour\",\"fields\":[{\"name\":\"tumourId\",\"type\":{\"type\":\"string\",\"avro.java.string\":\"String\"},\"doc\":\"TumourId in GMS\"},{\"name\":\"tumourLocalId\",\"type\":{\"type\":\"string\",\"avro.java.string\":\"String\"},\"doc\":\"Local hospital tumour ID from the GLH Laboratory Information Management System (LIMS) in GMS\"},{\"name\":\"tumourType\",\"type\":{\"type\":\"enum\",\"name\":\"TumourType\",\"doc\":\"NOTE: This has been changed completely, the previous tumour type has been split into TumourPresentation and PrimaryOrMetastatic\",\"symbols\":[\"BRAIN_TUMOUR\",\"HAEMATOLOGICAL_MALIGNANCY_SOLID_SAMPLE\",\"HAEMATOLOGICAL_MALIGNANCY_LIQUID_SAMPLE\",\"SOLID_TUMOUR_METASTATIC\",\"SOLID_TUMOUR_PRIMARY\",\"SOLID_TUMOUR\",\"UNKNOWN\"]},\"doc\":\"tumourType\"},{\"name\":\"tumourParentId\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"Parent Tumour UID if this tumour is metastatic\"},{\"name\":\"tumourDiagnosisDate\",\"type\":[\"null\",{\"type\":\"record\",\"name\":\"Date\",\"doc\":\"This defines a date record\",\"fields\":[{\"name\":\"year\",\"type\":\"int\",\"doc\":\"Format YYYY\"},{\"name\":\"month\",\"type\":[\"null\",\"int\"],\"doc\":\"Format MM. e.g June is 06\"},{\"name\":\"day\",\"type\":[\"null\",\"int\"],\"doc\":\"Format DD e.g. 12th of October is 12\"}]}],\"doc\":\"Date of Diagnosis of the specific tumour\"},{\"name\":\"tumourDescription\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"Description of the tumour\"},{\"name\":\"tumourMorphologies\",\"type\":[\"null\",{\"type\":\"array\",\"items\":\"Morphology\"}],\"doc\":\"Morphology of the tumour\"},{\"name\":\"tumourTopographies\",\"type\":[\"null\",{\"type\":\"array\",\"items\":\"Topography\"}],\"doc\":\"Topography of the tumour\"},{\"name\":\"tumourPrimaryTopographies\",\"type\":[\"null\",{\"type\":\"array\",\"items\":\"Topography\"}],\"doc\":\"Associated primary topography for metastatic tumours\"},{\"name\":\"tumourGrade\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"Grade of the Tumour\"},{\"name\":\"tumourStage\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}],\"doc\":\"Stage of the Tumour\"},{\"name\":\"tumourPrognosticScore\",\"type\":[\"null\",{\"type\":\"string\",\"avro.j","ava.string\":\"String\"}],\"doc\":\"Prognostic Score of the Tumour\"},{\"name\":\"tumourPresentation\",\"type\":[\"null\",{\"type\":\"enum\",\"name\":\"TumourPresentation\",\"symbols\":[\"FIRST_PRESENTATION\",\"RECURRENCE\",\"UNKNOWN\"]}],\"doc\":\"In GMS, tumour presentation\"},{\"name\":\"primaryOrMetastatic\",\"type\":[\"null\",{\"type\":\"enum\",\"name\":\"PrimaryOrMetastatic\",\"symbols\":[\"PRIMARY\",\"METASTATIC\",\"UNKNOWN\",\"NOT_APPLICABLE\"]}],\"doc\":\"In GMS, primary or metastatic\"}]}}],\"doc\":\"In GMS, for all tumours for the CancerParticipant, independent of any samples\"},{\"name\":\"previousTreatment\",\"type\":[\"null\",{\"type\":\"array\",\"items\":{\"type\":\"record\",\"name\":\"PreviousTreatment\",\"doc\":\"In GMS, Previous Treatment of Patient\",\"fields\":[{\"name\":\"previousTreatmentType\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}]},{\"name\":\"previousTreatmentName\",\"type\":[\"null\",{\"type\":\"string\",\"avro.java.string\":\"String\"}]},{\"name\":\"previousTreatmentDate\",\"type\":[\"null\",\"Date\"]}]}}],\"doc\":\"In GMS, any previous treatment recorded in TOMs\"}]}");
  public static org.apache.avro.Schema getClassSchema() { return SCHEMA$; }
  /** Year of birth for the cancer participant */
   private java.lang.Integer yearOfBirth;
  /** Morphology of any tumours
        NOTE: In GMS, this field is deprecated as morphology will be in sample or with respect to a tumour record */
   private java.util.List morphology;
  /** Flag indicating if the participant is ready for analysis
        NOTE: In GMS, this will default to true */
   private boolean readyForAnalysis;
  /** What has this participant consented to?
        A participant that has been consented to the programme should also have sequence data associated with them; however
        this needs to be programmatically checked */
   private org.gel.models.participant.avro.ConsentStatus consentStatus;
  /** What has this participant consented in the context of a Genomic Test? */
   private org.gel.models.participant.avro.GmsConsentStatus testConsentStatus;
  /** Center
        NOTE: In GMS, this will be taken from the ReferralTest and duplicated here */
   private java.lang.String center;
  /** Individual identifier */
   private java.lang.String individualId;
  /** This is a human readable participant ID */
   private java.lang.String participantId;
  /** This should be an enumeration when it is well defined
        blood, breast, prostate, colorectal, cll, aml, renal, ovarian, skin, lymphNode, bone, saliva //for individual - there could be more than I have listed here, in fact there definitely will.
        In GMS, this field is deprecated */
   private java.util.List primaryDiagnosisDisease;
  /** This should be an enumeration when it is well defined
        blood, breast, prostate, colorectal, cll, aml, renal, ovarian, skin, lymphNode, bone, saliva //for individual - there could be more than I have listed here, in fact there definitely will.
        In GMS, this field is deprecated */
   private java.util.List primaryDiagnosisSubDisease;
  /** Sex */
   private org.gel.models.participant.avro.Sex sex;
  /** We could add a map here to store additional information for example URIs to images, ECGs, etc */
   private java.util.Map additionalInformation;
  /** assigned ICD10 code
        IN GMS, this is deprecated */
   private java.util.List assignedICD10;
  /** List of tumour samples
        IN GMS, this is deprecated and moved to ReferralTest */
   private java.util.List tumourSamples;
  /** List of germline samples
        IN GMS, this is deprecated and moved to ReferralTest */
   private java.util.List germlineSamples;
  /** Model version number */
   private org.gel.models.participant.avro.VersionControl versionControl;
  /** Individual UID in GMS */
   private java.lang.String participantUid;
  /** In GMS, for all tumours for the CancerParticipant, independent of any samples */
   private java.util.List tumours;
  /** In GMS, any previous treatment recorded in TOMs */
   private java.util.List previousTreatment;

  /**
   * 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 CancerParticipant() {}

  /**
   * All-args constructor.
   */
  public CancerParticipant(java.lang.Integer yearOfBirth, java.util.List morphology, java.lang.Boolean readyForAnalysis, org.gel.models.participant.avro.ConsentStatus consentStatus, org.gel.models.participant.avro.GmsConsentStatus testConsentStatus, java.lang.String center, java.lang.String individualId, java.lang.String participantId, java.util.List primaryDiagnosisDisease, java.util.List primaryDiagnosisSubDisease, org.gel.models.participant.avro.Sex sex, java.util.Map additionalInformation, java.util.List assignedICD10, java.util.List tumourSamples, java.util.List germlineSamples, org.gel.models.participant.avro.VersionControl versionControl, java.lang.String participantUid, java.util.List tumours, java.util.List previousTreatment) {
    this.yearOfBirth = yearOfBirth;
    this.morphology = morphology;
    this.readyForAnalysis = readyForAnalysis;
    this.consentStatus = consentStatus;
    this.testConsentStatus = testConsentStatus;
    this.center = center;
    this.individualId = individualId;
    this.participantId = participantId;
    this.primaryDiagnosisDisease = primaryDiagnosisDisease;
    this.primaryDiagnosisSubDisease = primaryDiagnosisSubDisease;
    this.sex = sex;
    this.additionalInformation = additionalInformation;
    this.assignedICD10 = assignedICD10;
    this.tumourSamples = tumourSamples;
    this.germlineSamples = germlineSamples;
    this.versionControl = versionControl;
    this.participantUid = participantUid;
    this.tumours = tumours;
    this.previousTreatment = previousTreatment;
  }

  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 yearOfBirth;
    case 1: return morphology;
    case 2: return readyForAnalysis;
    case 3: return consentStatus;
    case 4: return testConsentStatus;
    case 5: return center;
    case 6: return individualId;
    case 7: return participantId;
    case 8: return primaryDiagnosisDisease;
    case 9: return primaryDiagnosisSubDisease;
    case 10: return sex;
    case 11: return additionalInformation;
    case 12: return assignedICD10;
    case 13: return tumourSamples;
    case 14: return germlineSamples;
    case 15: return versionControl;
    case 16: return participantUid;
    case 17: return tumours;
    case 18: return previousTreatment;
    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: yearOfBirth = (java.lang.Integer)value$; break;
    case 1: morphology = (java.util.List)value$; break;
    case 2: readyForAnalysis = (java.lang.Boolean)value$; break;
    case 3: consentStatus = (org.gel.models.participant.avro.ConsentStatus)value$; break;
    case 4: testConsentStatus = (org.gel.models.participant.avro.GmsConsentStatus)value$; break;
    case 5: center = (java.lang.String)value$; break;
    case 6: individualId = (java.lang.String)value$; break;
    case 7: participantId = (java.lang.String)value$; break;
    case 8: primaryDiagnosisDisease = (java.util.List)value$; break;
    case 9: primaryDiagnosisSubDisease = (java.util.List)value$; break;
    case 10: sex = (org.gel.models.participant.avro.Sex)value$; break;
    case 11: additionalInformation = (java.util.Map)value$; break;
    case 12: assignedICD10 = (java.util.List)value$; break;
    case 13: tumourSamples = (java.util.List)value$; break;
    case 14: germlineSamples = (java.util.List)value$; break;
    case 15: versionControl = (org.gel.models.participant.avro.VersionControl)value$; break;
    case 16: participantUid = (java.lang.String)value$; break;
    case 17: tumours = (java.util.List)value$; break;
    case 18: previousTreatment = (java.util.List)value$; break;
    default: throw new org.apache.avro.AvroRuntimeException("Bad index");
    }
  }

  /**
   * Gets the value of the 'yearOfBirth' field.
   * Year of birth for the cancer participant   */
  public java.lang.Integer getYearOfBirth() {
    return yearOfBirth;
  }

  /**
   * Sets the value of the 'yearOfBirth' field.
   * Year of birth for the cancer participant   * @param value the value to set.
   */
  public void setYearOfBirth(java.lang.Integer value) {
    this.yearOfBirth = value;
  }

  /**
   * Gets the value of the 'morphology' field.
   * Morphology of any tumours
        NOTE: In GMS, this field is deprecated as morphology will be in sample or with respect to a tumour record   */
  public java.util.List getMorphology() {
    return morphology;
  }

  /**
   * Sets the value of the 'morphology' field.
   * Morphology of any tumours
        NOTE: In GMS, this field is deprecated as morphology will be in sample or with respect to a tumour record   * @param value the value to set.
   */
  public void setMorphology(java.util.List value) {
    this.morphology = value;
  }

  /**
   * Gets the value of the 'readyForAnalysis' field.
   * Flag indicating if the participant is ready for analysis
        NOTE: In GMS, this will default to true   */
  public java.lang.Boolean getReadyForAnalysis() {
    return readyForAnalysis;
  }

  /**
   * Sets the value of the 'readyForAnalysis' field.
   * Flag indicating if the participant is ready for analysis
        NOTE: In GMS, this will default to true   * @param value the value to set.
   */
  public void setReadyForAnalysis(java.lang.Boolean value) {
    this.readyForAnalysis = value;
  }

  /**
   * Gets the value of the 'consentStatus' field.
   * What has this participant consented to?
        A participant that has been consented to the programme should also have sequence data associated with them; however
        this needs to be programmatically checked   */
  public org.gel.models.participant.avro.ConsentStatus getConsentStatus() {
    return consentStatus;
  }

  /**
   * Sets the value of the 'consentStatus' field.
   * What has this participant consented to?
        A participant that has been consented to the programme should also have sequence data associated with them; however
        this needs to be programmatically checked   * @param value the value to set.
   */
  public void setConsentStatus(org.gel.models.participant.avro.ConsentStatus value) {
    this.consentStatus = value;
  }

  /**
   * Gets the value of the 'testConsentStatus' field.
   * What has this participant consented in the context of a Genomic Test?   */
  public org.gel.models.participant.avro.GmsConsentStatus getTestConsentStatus() {
    return testConsentStatus;
  }

  /**
   * Sets the value of the 'testConsentStatus' field.
   * What has this participant consented in the context of a Genomic Test?   * @param value the value to set.
   */
  public void setTestConsentStatus(org.gel.models.participant.avro.GmsConsentStatus value) {
    this.testConsentStatus = value;
  }

  /**
   * Gets the value of the 'center' field.
   * Center
        NOTE: In GMS, this will be taken from the ReferralTest and duplicated here   */
  public java.lang.String getCenter() {
    return center;
  }

  /**
   * Sets the value of the 'center' field.
   * Center
        NOTE: In GMS, this will be taken from the ReferralTest and duplicated here   * @param value the value to set.
   */
  public void setCenter(java.lang.String value) {
    this.center = value;
  }

  /**
   * Gets the value of the 'individualId' field.
   * Individual identifier   */
  public java.lang.String getIndividualId() {
    return individualId;
  }

  /**
   * Sets the value of the 'individualId' field.
   * Individual identifier   * @param value the value to set.
   */
  public void setIndividualId(java.lang.String value) {
    this.individualId = value;
  }

  /**
   * Gets the value of the 'participantId' field.
   * This is a human readable participant ID   */
  public java.lang.String getParticipantId() {
    return participantId;
  }

  /**
   * Sets the value of the 'participantId' field.
   * This is a human readable participant ID   * @param value the value to set.
   */
  public void setParticipantId(java.lang.String value) {
    this.participantId = value;
  }

  /**
   * Gets the value of the 'primaryDiagnosisDisease' field.
   * This should be an enumeration when it is well defined
        blood, breast, prostate, colorectal, cll, aml, renal, ovarian, skin, lymphNode, bone, saliva //for individual - there could be more than I have listed here, in fact there definitely will.
        In GMS, this field is deprecated   */
  public java.util.List getPrimaryDiagnosisDisease() {
    return primaryDiagnosisDisease;
  }

  /**
   * Sets the value of the 'primaryDiagnosisDisease' field.
   * This should be an enumeration when it is well defined
        blood, breast, prostate, colorectal, cll, aml, renal, ovarian, skin, lymphNode, bone, saliva //for individual - there could be more than I have listed here, in fact there definitely will.
        In GMS, this field is deprecated   * @param value the value to set.
   */
  public void setPrimaryDiagnosisDisease(java.util.List value) {
    this.primaryDiagnosisDisease = value;
  }

  /**
   * Gets the value of the 'primaryDiagnosisSubDisease' field.
   * This should be an enumeration when it is well defined
        blood, breast, prostate, colorectal, cll, aml, renal, ovarian, skin, lymphNode, bone, saliva //for individual - there could be more than I have listed here, in fact there definitely will.
        In GMS, this field is deprecated   */
  public java.util.List getPrimaryDiagnosisSubDisease() {
    return primaryDiagnosisSubDisease;
  }

  /**
   * Sets the value of the 'primaryDiagnosisSubDisease' field.
   * This should be an enumeration when it is well defined
        blood, breast, prostate, colorectal, cll, aml, renal, ovarian, skin, lymphNode, bone, saliva //for individual - there could be more than I have listed here, in fact there definitely will.
        In GMS, this field is deprecated   * @param value the value to set.
   */
  public void setPrimaryDiagnosisSubDisease(java.util.List value) {
    this.primaryDiagnosisSubDisease = value;
  }

  /**
   * Gets the value of the 'sex' field.
   * Sex   */
  public org.gel.models.participant.avro.Sex getSex() {
    return sex;
  }

  /**
   * Sets the value of the 'sex' field.
   * Sex   * @param value the value to set.
   */
  public void setSex(org.gel.models.participant.avro.Sex value) {
    this.sex = value;
  }

  /**
   * Gets the value of the 'additionalInformation' field.
   * We could add a map here to store additional information for example URIs to images, ECGs, etc   */
  public java.util.Map getAdditionalInformation() {
    return additionalInformation;
  }

  /**
   * Sets the value of the 'additionalInformation' field.
   * We could add a map here to store additional information for example URIs to images, ECGs, etc   * @param value the value to set.
   */
  public void setAdditionalInformation(java.util.Map value) {
    this.additionalInformation = value;
  }

  /**
   * Gets the value of the 'assignedICD10' field.
   * assigned ICD10 code
        IN GMS, this is deprecated   */
  public java.util.List getAssignedICD10() {
    return assignedICD10;
  }

  /**
   * Sets the value of the 'assignedICD10' field.
   * assigned ICD10 code
        IN GMS, this is deprecated   * @param value the value to set.
   */
  public void setAssignedICD10(java.util.List value) {
    this.assignedICD10 = value;
  }

  /**
   * Gets the value of the 'tumourSamples' field.
   * List of tumour samples
        IN GMS, this is deprecated and moved to ReferralTest   */
  public java.util.List getTumourSamples() {
    return tumourSamples;
  }

  /**
   * Sets the value of the 'tumourSamples' field.
   * List of tumour samples
        IN GMS, this is deprecated and moved to ReferralTest   * @param value the value to set.
   */
  public void setTumourSamples(java.util.List value) {
    this.tumourSamples = value;
  }

  /**
   * Gets the value of the 'germlineSamples' field.
   * List of germline samples
        IN GMS, this is deprecated and moved to ReferralTest   */
  public java.util.List getGermlineSamples() {
    return germlineSamples;
  }

  /**
   * Sets the value of the 'germlineSamples' field.
   * List of germline samples
        IN GMS, this is deprecated and moved to ReferralTest   * @param value the value to set.
   */
  public void setGermlineSamples(java.util.List value) {
    this.germlineSamples = value;
  }

  /**
   * Gets the value of the 'versionControl' field.
   * Model version number   */
  public org.gel.models.participant.avro.VersionControl getVersionControl() {
    return versionControl;
  }

  /**
   * Sets the value of the 'versionControl' field.
   * Model version number   * @param value the value to set.
   */
  public void setVersionControl(org.gel.models.participant.avro.VersionControl value) {
    this.versionControl = value;
  }

  /**
   * Gets the value of the 'participantUid' field.
   * Individual UID in GMS   */
  public java.lang.String getParticipantUid() {
    return participantUid;
  }

  /**
   * Sets the value of the 'participantUid' field.
   * Individual UID in GMS   * @param value the value to set.
   */
  public void setParticipantUid(java.lang.String value) {
    this.participantUid = value;
  }

  /**
   * Gets the value of the 'tumours' field.
   * In GMS, for all tumours for the CancerParticipant, independent of any samples   */
  public java.util.List getTumours() {
    return tumours;
  }

  /**
   * Sets the value of the 'tumours' field.
   * In GMS, for all tumours for the CancerParticipant, independent of any samples   * @param value the value to set.
   */
  public void setTumours(java.util.List value) {
    this.tumours = value;
  }

  /**
   * Gets the value of the 'previousTreatment' field.
   * In GMS, any previous treatment recorded in TOMs   */
  public java.util.List getPreviousTreatment() {
    return previousTreatment;
  }

  /**
   * Sets the value of the 'previousTreatment' field.
   * In GMS, any previous treatment recorded in TOMs   * @param value the value to set.
   */
  public void setPreviousTreatment(java.util.List value) {
    this.previousTreatment = value;
  }

  /** Creates a new CancerParticipant RecordBuilder */
  public static org.gel.models.participant.avro.CancerParticipant.Builder newBuilder() {
    return new org.gel.models.participant.avro.CancerParticipant.Builder();
  }
  
  /** Creates a new CancerParticipant RecordBuilder by copying an existing Builder */
  public static org.gel.models.participant.avro.CancerParticipant.Builder newBuilder(org.gel.models.participant.avro.CancerParticipant.Builder other) {
    return new org.gel.models.participant.avro.CancerParticipant.Builder(other);
  }
  
  /** Creates a new CancerParticipant RecordBuilder by copying an existing CancerParticipant instance */
  public static org.gel.models.participant.avro.CancerParticipant.Builder newBuilder(org.gel.models.participant.avro.CancerParticipant other) {
    return new org.gel.models.participant.avro.CancerParticipant.Builder(other);
  }
  
  /**
   * RecordBuilder for CancerParticipant instances.
   */
  public static class Builder extends org.apache.avro.specific.SpecificRecordBuilderBase
    implements org.apache.avro.data.RecordBuilder {

    private java.lang.Integer yearOfBirth;
    private java.util.List morphology;
    private boolean readyForAnalysis;
    private org.gel.models.participant.avro.ConsentStatus consentStatus;
    private org.gel.models.participant.avro.GmsConsentStatus testConsentStatus;
    private java.lang.String center;
    private java.lang.String individualId;
    private java.lang.String participantId;
    private java.util.List primaryDiagnosisDisease;
    private java.util.List primaryDiagnosisSubDisease;
    private org.gel.models.participant.avro.Sex sex;
    private java.util.Map additionalInformation;
    private java.util.List assignedICD10;
    private java.util.List tumourSamples;
    private java.util.List germlineSamples;
    private org.gel.models.participant.avro.VersionControl versionControl;
    private java.lang.String participantUid;
    private java.util.List tumours;
    private java.util.List previousTreatment;

    /** Creates a new Builder */
    private Builder() {
      super(org.gel.models.participant.avro.CancerParticipant.SCHEMA$);
    }
    
    /** Creates a Builder by copying an existing Builder */
    private Builder(org.gel.models.participant.avro.CancerParticipant.Builder other) {
      super(other);
      if (isValidValue(fields()[0], other.yearOfBirth)) {
        this.yearOfBirth = data().deepCopy(fields()[0].schema(), other.yearOfBirth);
        fieldSetFlags()[0] = true;
      }
      if (isValidValue(fields()[1], other.morphology)) {
        this.morphology = data().deepCopy(fields()[1].schema(), other.morphology);
        fieldSetFlags()[1] = true;
      }
      if (isValidValue(fields()[2], other.readyForAnalysis)) {
        this.readyForAnalysis = data().deepCopy(fields()[2].schema(), other.readyForAnalysis);
        fieldSetFlags()[2] = true;
      }
      if (isValidValue(fields()[3], other.consentStatus)) {
        this.consentStatus = data().deepCopy(fields()[3].schema(), other.consentStatus);
        fieldSetFlags()[3] = true;
      }
      if (isValidValue(fields()[4], other.testConsentStatus)) {
        this.testConsentStatus = data().deepCopy(fields()[4].schema(), other.testConsentStatus);
        fieldSetFlags()[4] = true;
      }
      if (isValidValue(fields()[5], other.center)) {
        this.center = data().deepCopy(fields()[5].schema(), other.center);
        fieldSetFlags()[5] = true;
      }
      if (isValidValue(fields()[6], other.individualId)) {
        this.individualId = data().deepCopy(fields()[6].schema(), other.individualId);
        fieldSetFlags()[6] = true;
      }
      if (isValidValue(fields()[7], other.participantId)) {
        this.participantId = data().deepCopy(fields()[7].schema(), other.participantId);
        fieldSetFlags()[7] = true;
      }
      if (isValidValue(fields()[8], other.primaryDiagnosisDisease)) {
        this.primaryDiagnosisDisease = data().deepCopy(fields()[8].schema(), other.primaryDiagnosisDisease);
        fieldSetFlags()[8] = true;
      }
      if (isValidValue(fields()[9], other.primaryDiagnosisSubDisease)) {
        this.primaryDiagnosisSubDisease = data().deepCopy(fields()[9].schema(), other.primaryDiagnosisSubDisease);
        fieldSetFlags()[9] = true;
      }
      if (isValidValue(fields()[10], other.sex)) {
        this.sex = data().deepCopy(fields()[10].schema(), other.sex);
        fieldSetFlags()[10] = true;
      }
      if (isValidValue(fields()[11], other.additionalInformation)) {
        this.additionalInformation = data().deepCopy(fields()[11].schema(), other.additionalInformation);
        fieldSetFlags()[11] = true;
      }
      if (isValidValue(fields()[12], other.assignedICD10)) {
        this.assignedICD10 = data().deepCopy(fields()[12].schema(), other.assignedICD10);
        fieldSetFlags()[12] = true;
      }
      if (isValidValue(fields()[13], other.tumourSamples)) {
        this.tumourSamples = data().deepCopy(fields()[13].schema(), other.tumourSamples);
        fieldSetFlags()[13] = true;
      }
      if (isValidValue(fields()[14], other.germlineSamples)) {
        this.germlineSamples = data().deepCopy(fields()[14].schema(), other.germlineSamples);
        fieldSetFlags()[14] = true;
      }
      if (isValidValue(fields()[15], other.versionControl)) {
        this.versionControl = data().deepCopy(fields()[15].schema(), other.versionControl);
        fieldSetFlags()[15] = true;
      }
      if (isValidValue(fields()[16], other.participantUid)) {
        this.participantUid = data().deepCopy(fields()[16].schema(), other.participantUid);
        fieldSetFlags()[16] = true;
      }
      if (isValidValue(fields()[17], other.tumours)) {
        this.tumours = data().deepCopy(fields()[17].schema(), other.tumours);
        fieldSetFlags()[17] = true;
      }
      if (isValidValue(fields()[18], other.previousTreatment)) {
        this.previousTreatment = data().deepCopy(fields()[18].schema(), other.previousTreatment);
        fieldSetFlags()[18] = true;
      }
    }
    
    /** Creates a Builder by copying an existing CancerParticipant instance */
    private Builder(org.gel.models.participant.avro.CancerParticipant other) {
            super(org.gel.models.participant.avro.CancerParticipant.SCHEMA$);
      if (isValidValue(fields()[0], other.yearOfBirth)) {
        this.yearOfBirth = data().deepCopy(fields()[0].schema(), other.yearOfBirth);
        fieldSetFlags()[0] = true;
      }
      if (isValidValue(fields()[1], other.morphology)) {
        this.morphology = data().deepCopy(fields()[1].schema(), other.morphology);
        fieldSetFlags()[1] = true;
      }
      if (isValidValue(fields()[2], other.readyForAnalysis)) {
        this.readyForAnalysis = data().deepCopy(fields()[2].schema(), other.readyForAnalysis);
        fieldSetFlags()[2] = true;
      }
      if (isValidValue(fields()[3], other.consentStatus)) {
        this.consentStatus = data().deepCopy(fields()[3].schema(), other.consentStatus);
        fieldSetFlags()[3] = true;
      }
      if (isValidValue(fields()[4], other.testConsentStatus)) {
        this.testConsentStatus = data().deepCopy(fields()[4].schema(), other.testConsentStatus);
        fieldSetFlags()[4] = true;
      }
      if (isValidValue(fields()[5], other.center)) {
        this.center = data().deepCopy(fields()[5].schema(), other.center);
        fieldSetFlags()[5] = true;
      }
      if (isValidValue(fields()[6], other.individualId)) {
        this.individualId = data().deepCopy(fields()[6].schema(), other.individualId);
        fieldSetFlags()[6] = true;
      }
      if (isValidValue(fields()[7], other.participantId)) {
        this.participantId = data().deepCopy(fields()[7].schema(), other.participantId);
        fieldSetFlags()[7] = true;
      }
      if (isValidValue(fields()[8], other.primaryDiagnosisDisease)) {
        this.primaryDiagnosisDisease = data().deepCopy(fields()[8].schema(), other.primaryDiagnosisDisease);
        fieldSetFlags()[8] = true;
      }
      if (isValidValue(fields()[9], other.primaryDiagnosisSubDisease)) {
        this.primaryDiagnosisSubDisease = data().deepCopy(fields()[9].schema(), other.primaryDiagnosisSubDisease);
        fieldSetFlags()[9] = true;
      }
      if (isValidValue(fields()[10], other.sex)) {
        this.sex = data().deepCopy(fields()[10].schema(), other.sex);
        fieldSetFlags()[10] = true;
      }
      if (isValidValue(fields()[11], other.additionalInformation)) {
        this.additionalInformation = data().deepCopy(fields()[11].schema(), other.additionalInformation);
        fieldSetFlags()[11] = true;
      }
      if (isValidValue(fields()[12], other.assignedICD10)) {
        this.assignedICD10 = data().deepCopy(fields()[12].schema(), other.assignedICD10);
        fieldSetFlags()[12] = true;
      }
      if (isValidValue(fields()[13], other.tumourSamples)) {
        this.tumourSamples = data().deepCopy(fields()[13].schema(), other.tumourSamples);
        fieldSetFlags()[13] = true;
      }
      if (isValidValue(fields()[14], other.germlineSamples)) {
        this.germlineSamples = data().deepCopy(fields()[14].schema(), other.germlineSamples);
        fieldSetFlags()[14] = true;
      }
      if (isValidValue(fields()[15], other.versionControl)) {
        this.versionControl = data().deepCopy(fields()[15].schema(), other.versionControl);
        fieldSetFlags()[15] = true;
      }
      if (isValidValue(fields()[16], other.participantUid)) {
        this.participantUid = data().deepCopy(fields()[16].schema(), other.participantUid);
        fieldSetFlags()[16] = true;
      }
      if (isValidValue(fields()[17], other.tumours)) {
        this.tumours = data().deepCopy(fields()[17].schema(), other.tumours);
        fieldSetFlags()[17] = true;
      }
      if (isValidValue(fields()[18], other.previousTreatment)) {
        this.previousTreatment = data().deepCopy(fields()[18].schema(), other.previousTreatment);
        fieldSetFlags()[18] = true;
      }
    }

    /** Gets the value of the 'yearOfBirth' field */
    public java.lang.Integer getYearOfBirth() {
      return yearOfBirth;
    }
    
    /** Sets the value of the 'yearOfBirth' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder setYearOfBirth(java.lang.Integer value) {
      validate(fields()[0], value);
      this.yearOfBirth = value;
      fieldSetFlags()[0] = true;
      return this; 
    }
    
    /** Checks whether the 'yearOfBirth' field has been set */
    public boolean hasYearOfBirth() {
      return fieldSetFlags()[0];
    }
    
    /** Clears the value of the 'yearOfBirth' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder clearYearOfBirth() {
      yearOfBirth = null;
      fieldSetFlags()[0] = false;
      return this;
    }

    /** Gets the value of the 'morphology' field */
    public java.util.List getMorphology() {
      return morphology;
    }
    
    /** Sets the value of the 'morphology' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder setMorphology(java.util.List value) {
      validate(fields()[1], value);
      this.morphology = value;
      fieldSetFlags()[1] = true;
      return this; 
    }
    
    /** Checks whether the 'morphology' field has been set */
    public boolean hasMorphology() {
      return fieldSetFlags()[1];
    }
    
    /** Clears the value of the 'morphology' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder clearMorphology() {
      morphology = null;
      fieldSetFlags()[1] = false;
      return this;
    }

    /** Gets the value of the 'readyForAnalysis' field */
    public java.lang.Boolean getReadyForAnalysis() {
      return readyForAnalysis;
    }
    
    /** Sets the value of the 'readyForAnalysis' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder setReadyForAnalysis(boolean value) {
      validate(fields()[2], value);
      this.readyForAnalysis = value;
      fieldSetFlags()[2] = true;
      return this; 
    }
    
    /** Checks whether the 'readyForAnalysis' field has been set */
    public boolean hasReadyForAnalysis() {
      return fieldSetFlags()[2];
    }
    
    /** Clears the value of the 'readyForAnalysis' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder clearReadyForAnalysis() {
      fieldSetFlags()[2] = false;
      return this;
    }

    /** Gets the value of the 'consentStatus' field */
    public org.gel.models.participant.avro.ConsentStatus getConsentStatus() {
      return consentStatus;
    }
    
    /** Sets the value of the 'consentStatus' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder setConsentStatus(org.gel.models.participant.avro.ConsentStatus value) {
      validate(fields()[3], value);
      this.consentStatus = value;
      fieldSetFlags()[3] = true;
      return this; 
    }
    
    /** Checks whether the 'consentStatus' field has been set */
    public boolean hasConsentStatus() {
      return fieldSetFlags()[3];
    }
    
    /** Clears the value of the 'consentStatus' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder clearConsentStatus() {
      consentStatus = null;
      fieldSetFlags()[3] = false;
      return this;
    }

    /** Gets the value of the 'testConsentStatus' field */
    public org.gel.models.participant.avro.GmsConsentStatus getTestConsentStatus() {
      return testConsentStatus;
    }
    
    /** Sets the value of the 'testConsentStatus' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder setTestConsentStatus(org.gel.models.participant.avro.GmsConsentStatus value) {
      validate(fields()[4], value);
      this.testConsentStatus = value;
      fieldSetFlags()[4] = true;
      return this; 
    }
    
    /** Checks whether the 'testConsentStatus' field has been set */
    public boolean hasTestConsentStatus() {
      return fieldSetFlags()[4];
    }
    
    /** Clears the value of the 'testConsentStatus' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder clearTestConsentStatus() {
      testConsentStatus = null;
      fieldSetFlags()[4] = false;
      return this;
    }

    /** Gets the value of the 'center' field */
    public java.lang.String getCenter() {
      return center;
    }
    
    /** Sets the value of the 'center' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder setCenter(java.lang.String value) {
      validate(fields()[5], value);
      this.center = value;
      fieldSetFlags()[5] = true;
      return this; 
    }
    
    /** Checks whether the 'center' field has been set */
    public boolean hasCenter() {
      return fieldSetFlags()[5];
    }
    
    /** Clears the value of the 'center' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder clearCenter() {
      center = null;
      fieldSetFlags()[5] = false;
      return this;
    }

    /** Gets the value of the 'individualId' field */
    public java.lang.String getIndividualId() {
      return individualId;
    }
    
    /** Sets the value of the 'individualId' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder setIndividualId(java.lang.String value) {
      validate(fields()[6], value);
      this.individualId = value;
      fieldSetFlags()[6] = true;
      return this; 
    }
    
    /** Checks whether the 'individualId' field has been set */
    public boolean hasIndividualId() {
      return fieldSetFlags()[6];
    }
    
    /** Clears the value of the 'individualId' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder clearIndividualId() {
      individualId = null;
      fieldSetFlags()[6] = false;
      return this;
    }

    /** Gets the value of the 'participantId' field */
    public java.lang.String getParticipantId() {
      return participantId;
    }
    
    /** Sets the value of the 'participantId' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder setParticipantId(java.lang.String value) {
      validate(fields()[7], value);
      this.participantId = value;
      fieldSetFlags()[7] = true;
      return this; 
    }
    
    /** Checks whether the 'participantId' field has been set */
    public boolean hasParticipantId() {
      return fieldSetFlags()[7];
    }
    
    /** Clears the value of the 'participantId' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder clearParticipantId() {
      participantId = null;
      fieldSetFlags()[7] = false;
      return this;
    }

    /** Gets the value of the 'primaryDiagnosisDisease' field */
    public java.util.List getPrimaryDiagnosisDisease() {
      return primaryDiagnosisDisease;
    }
    
    /** Sets the value of the 'primaryDiagnosisDisease' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder setPrimaryDiagnosisDisease(java.util.List value) {
      validate(fields()[8], value);
      this.primaryDiagnosisDisease = value;
      fieldSetFlags()[8] = true;
      return this; 
    }
    
    /** Checks whether the 'primaryDiagnosisDisease' field has been set */
    public boolean hasPrimaryDiagnosisDisease() {
      return fieldSetFlags()[8];
    }
    
    /** Clears the value of the 'primaryDiagnosisDisease' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder clearPrimaryDiagnosisDisease() {
      primaryDiagnosisDisease = null;
      fieldSetFlags()[8] = false;
      return this;
    }

    /** Gets the value of the 'primaryDiagnosisSubDisease' field */
    public java.util.List getPrimaryDiagnosisSubDisease() {
      return primaryDiagnosisSubDisease;
    }
    
    /** Sets the value of the 'primaryDiagnosisSubDisease' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder setPrimaryDiagnosisSubDisease(java.util.List value) {
      validate(fields()[9], value);
      this.primaryDiagnosisSubDisease = value;
      fieldSetFlags()[9] = true;
      return this; 
    }
    
    /** Checks whether the 'primaryDiagnosisSubDisease' field has been set */
    public boolean hasPrimaryDiagnosisSubDisease() {
      return fieldSetFlags()[9];
    }
    
    /** Clears the value of the 'primaryDiagnosisSubDisease' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder clearPrimaryDiagnosisSubDisease() {
      primaryDiagnosisSubDisease = null;
      fieldSetFlags()[9] = false;
      return this;
    }

    /** Gets the value of the 'sex' field */
    public org.gel.models.participant.avro.Sex getSex() {
      return sex;
    }
    
    /** Sets the value of the 'sex' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder setSex(org.gel.models.participant.avro.Sex value) {
      validate(fields()[10], value);
      this.sex = value;
      fieldSetFlags()[10] = true;
      return this; 
    }
    
    /** Checks whether the 'sex' field has been set */
    public boolean hasSex() {
      return fieldSetFlags()[10];
    }
    
    /** Clears the value of the 'sex' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder clearSex() {
      sex = null;
      fieldSetFlags()[10] = false;
      return this;
    }

    /** Gets the value of the 'additionalInformation' field */
    public java.util.Map getAdditionalInformation() {
      return additionalInformation;
    }
    
    /** Sets the value of the 'additionalInformation' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder setAdditionalInformation(java.util.Map value) {
      validate(fields()[11], value);
      this.additionalInformation = value;
      fieldSetFlags()[11] = true;
      return this; 
    }
    
    /** Checks whether the 'additionalInformation' field has been set */
    public boolean hasAdditionalInformation() {
      return fieldSetFlags()[11];
    }
    
    /** Clears the value of the 'additionalInformation' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder clearAdditionalInformation() {
      additionalInformation = null;
      fieldSetFlags()[11] = false;
      return this;
    }

    /** Gets the value of the 'assignedICD10' field */
    public java.util.List getAssignedICD10() {
      return assignedICD10;
    }
    
    /** Sets the value of the 'assignedICD10' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder setAssignedICD10(java.util.List value) {
      validate(fields()[12], value);
      this.assignedICD10 = value;
      fieldSetFlags()[12] = true;
      return this; 
    }
    
    /** Checks whether the 'assignedICD10' field has been set */
    public boolean hasAssignedICD10() {
      return fieldSetFlags()[12];
    }
    
    /** Clears the value of the 'assignedICD10' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder clearAssignedICD10() {
      assignedICD10 = null;
      fieldSetFlags()[12] = false;
      return this;
    }

    /** Gets the value of the 'tumourSamples' field */
    public java.util.List getTumourSamples() {
      return tumourSamples;
    }
    
    /** Sets the value of the 'tumourSamples' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder setTumourSamples(java.util.List value) {
      validate(fields()[13], value);
      this.tumourSamples = value;
      fieldSetFlags()[13] = true;
      return this; 
    }
    
    /** Checks whether the 'tumourSamples' field has been set */
    public boolean hasTumourSamples() {
      return fieldSetFlags()[13];
    }
    
    /** Clears the value of the 'tumourSamples' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder clearTumourSamples() {
      tumourSamples = null;
      fieldSetFlags()[13] = false;
      return this;
    }

    /** Gets the value of the 'germlineSamples' field */
    public java.util.List getGermlineSamples() {
      return germlineSamples;
    }
    
    /** Sets the value of the 'germlineSamples' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder setGermlineSamples(java.util.List value) {
      validate(fields()[14], value);
      this.germlineSamples = value;
      fieldSetFlags()[14] = true;
      return this; 
    }
    
    /** Checks whether the 'germlineSamples' field has been set */
    public boolean hasGermlineSamples() {
      return fieldSetFlags()[14];
    }
    
    /** Clears the value of the 'germlineSamples' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder clearGermlineSamples() {
      germlineSamples = null;
      fieldSetFlags()[14] = false;
      return this;
    }

    /** Gets the value of the 'versionControl' field */
    public org.gel.models.participant.avro.VersionControl getVersionControl() {
      return versionControl;
    }
    
    /** Sets the value of the 'versionControl' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder setVersionControl(org.gel.models.participant.avro.VersionControl value) {
      validate(fields()[15], value);
      this.versionControl = value;
      fieldSetFlags()[15] = true;
      return this; 
    }
    
    /** Checks whether the 'versionControl' field has been set */
    public boolean hasVersionControl() {
      return fieldSetFlags()[15];
    }
    
    /** Clears the value of the 'versionControl' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder clearVersionControl() {
      versionControl = null;
      fieldSetFlags()[15] = false;
      return this;
    }

    /** Gets the value of the 'participantUid' field */
    public java.lang.String getParticipantUid() {
      return participantUid;
    }
    
    /** Sets the value of the 'participantUid' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder setParticipantUid(java.lang.String value) {
      validate(fields()[16], value);
      this.participantUid = value;
      fieldSetFlags()[16] = true;
      return this; 
    }
    
    /** Checks whether the 'participantUid' field has been set */
    public boolean hasParticipantUid() {
      return fieldSetFlags()[16];
    }
    
    /** Clears the value of the 'participantUid' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder clearParticipantUid() {
      participantUid = null;
      fieldSetFlags()[16] = false;
      return this;
    }

    /** Gets the value of the 'tumours' field */
    public java.util.List getTumours() {
      return tumours;
    }
    
    /** Sets the value of the 'tumours' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder setTumours(java.util.List value) {
      validate(fields()[17], value);
      this.tumours = value;
      fieldSetFlags()[17] = true;
      return this; 
    }
    
    /** Checks whether the 'tumours' field has been set */
    public boolean hasTumours() {
      return fieldSetFlags()[17];
    }
    
    /** Clears the value of the 'tumours' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder clearTumours() {
      tumours = null;
      fieldSetFlags()[17] = false;
      return this;
    }

    /** Gets the value of the 'previousTreatment' field */
    public java.util.List getPreviousTreatment() {
      return previousTreatment;
    }
    
    /** Sets the value of the 'previousTreatment' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder setPreviousTreatment(java.util.List value) {
      validate(fields()[18], value);
      this.previousTreatment = value;
      fieldSetFlags()[18] = true;
      return this; 
    }
    
    /** Checks whether the 'previousTreatment' field has been set */
    public boolean hasPreviousTreatment() {
      return fieldSetFlags()[18];
    }
    
    /** Clears the value of the 'previousTreatment' field */
    public org.gel.models.participant.avro.CancerParticipant.Builder clearPreviousTreatment() {
      previousTreatment = null;
      fieldSetFlags()[18] = false;
      return this;
    }

    @Override
    public CancerParticipant build() {
      try {
        CancerParticipant record = new CancerParticipant();
        record.yearOfBirth = fieldSetFlags()[0] ? this.yearOfBirth : (java.lang.Integer) defaultValue(fields()[0]);
        record.morphology = fieldSetFlags()[1] ? this.morphology : (java.util.List) defaultValue(fields()[1]);
        record.readyForAnalysis = fieldSetFlags()[2] ? this.readyForAnalysis : (java.lang.Boolean) defaultValue(fields()[2]);
        record.consentStatus = fieldSetFlags()[3] ? this.consentStatus : (org.gel.models.participant.avro.ConsentStatus) defaultValue(fields()[3]);
        record.testConsentStatus = fieldSetFlags()[4] ? this.testConsentStatus : (org.gel.models.participant.avro.GmsConsentStatus) defaultValue(fields()[4]);
        record.center = fieldSetFlags()[5] ? this.center : (java.lang.String) defaultValue(fields()[5]);
        record.individualId = fieldSetFlags()[6] ? this.individualId : (java.lang.String) defaultValue(fields()[6]);
        record.participantId = fieldSetFlags()[7] ? this.participantId : (java.lang.String) defaultValue(fields()[7]);
        record.primaryDiagnosisDisease = fieldSetFlags()[8] ? this.primaryDiagnosisDisease : (java.util.List) defaultValue(fields()[8]);
        record.primaryDiagnosisSubDisease = fieldSetFlags()[9] ? this.primaryDiagnosisSubDisease : (java.util.List) defaultValue(fields()[9]);
        record.sex = fieldSetFlags()[10] ? this.sex : (org.gel.models.participant.avro.Sex) defaultValue(fields()[10]);
        record.additionalInformation = fieldSetFlags()[11] ? this.additionalInformation : (java.util.Map) defaultValue(fields()[11]);
        record.assignedICD10 = fieldSetFlags()[12] ? this.assignedICD10 : (java.util.List) defaultValue(fields()[12]);
        record.tumourSamples = fieldSetFlags()[13] ? this.tumourSamples : (java.util.List) defaultValue(fields()[13]);
        record.germlineSamples = fieldSetFlags()[14] ? this.germlineSamples : (java.util.List) defaultValue(fields()[14]);
        record.versionControl = fieldSetFlags()[15] ? this.versionControl : (org.gel.models.participant.avro.VersionControl) defaultValue(fields()[15]);
        record.participantUid = fieldSetFlags()[16] ? this.participantUid : (java.lang.String) defaultValue(fields()[16]);
        record.tumours = fieldSetFlags()[17] ? this.tumours : (java.util.List) defaultValue(fields()[17]);
        record.previousTreatment = fieldSetFlags()[18] ? this.previousTreatment : (java.util.List) defaultValue(fields()[18]);
        return record;
      } catch (Exception e) {
        throw new org.apache.avro.AvroRuntimeException(e);
      }
    }
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy