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

org.hl7.fhir.MedicationOrder Maven / Gradle / Ivy

Go to download

The quick library for the Clinical Quality Language Java reference implementation

There is a newer version: 3.15.0
Show newest version
//
// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.4.0-b180830.0438 
// See https://javaee.github.io/jaxb-v2/ 
// Any modifications to this file will be lost upon recompilation of the source schema. 
// Generated on: 2023.10.25 at 10:12:25 AM MDT 
//


package org.hl7.fhir;

import java.util.ArrayList;
import java.util.Collection;
import java.util.List;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlType;
import org.jvnet.jaxb2_commons.lang.Equals2;
import org.jvnet.jaxb2_commons.lang.EqualsStrategy2;
import org.jvnet.jaxb2_commons.lang.HashCode2;
import org.jvnet.jaxb2_commons.lang.HashCodeStrategy2;
import org.jvnet.jaxb2_commons.lang.JAXBEqualsStrategy;
import org.jvnet.jaxb2_commons.lang.JAXBHashCodeStrategy;
import org.jvnet.jaxb2_commons.lang.JAXBToStringStrategy;
import org.jvnet.jaxb2_commons.lang.ToString2;
import org.jvnet.jaxb2_commons.lang.ToStringStrategy2;
import org.jvnet.jaxb2_commons.locator.ObjectLocator;
import org.jvnet.jaxb2_commons.locator.util.LocatorUtils;


/**
 * If the element is present, it must have either a @value, an @id, or extensions
 * 
 * 

Java class for MedicationOrder complex type. * *

The following schema fragment specifies the expected content contained within this class. * *

 * <complexType name="MedicationOrder">
 *   <complexContent>
 *     <extension base="{http://hl7.org/fhir}DomainResource">
 *       <sequence>
 *         <element name="identifier" type="{http://hl7.org/fhir}Identifier" maxOccurs="unbounded" minOccurs="0"/>
 *         <element name="status" type="{http://hl7.org/fhir}MedicationOrderStatus" minOccurs="0"/>
 *         <choice>
 *           <element name="medicationCodeableConcept" type="{http://hl7.org/fhir}CodeableConcept"/>
 *           <element name="medicationReference" type="{http://hl7.org/fhir}Reference"/>
 *         </choice>
 *         <element name="patient" type="{http://hl7.org/fhir}Reference" minOccurs="0"/>
 *         <element name="encounter" type="{http://hl7.org/fhir}Reference" minOccurs="0"/>
 *         <element name="dateWritten" type="{http://hl7.org/fhir}dateTime" minOccurs="0"/>
 *         <element name="prescriber" type="{http://hl7.org/fhir}Reference" minOccurs="0"/>
 *         <element name="reasonCode" type="{http://hl7.org/fhir}CodeableConcept" maxOccurs="unbounded" minOccurs="0"/>
 *         <element name="reasonReference" type="{http://hl7.org/fhir}Reference" maxOccurs="unbounded" minOccurs="0"/>
 *         <element name="dateEnded" type="{http://hl7.org/fhir}dateTime" minOccurs="0"/>
 *         <element name="reasonEnded" type="{http://hl7.org/fhir}CodeableConcept" minOccurs="0"/>
 *         <element name="note" type="{http://hl7.org/fhir}Annotation" maxOccurs="unbounded" minOccurs="0"/>
 *         <element name="dosageInstruction" type="{http://hl7.org/fhir}MedicationOrder.DosageInstruction" maxOccurs="unbounded" minOccurs="0"/>
 *         <element name="dispenseRequest" type="{http://hl7.org/fhir}MedicationOrder.DispenseRequest" minOccurs="0"/>
 *         <element name="substitution" type="{http://hl7.org/fhir}MedicationOrder.Substitution" minOccurs="0"/>
 *         <element name="priorPrescription" type="{http://hl7.org/fhir}Reference" minOccurs="0"/>
 *       </sequence>
 *     </extension>
 *   </complexContent>
 * </complexType>
 * 
* * */ @XmlAccessorType(XmlAccessType.FIELD) @XmlType(name = "MedicationOrder", propOrder = { "identifier", "status", "medicationCodeableConcept", "medicationReference", "patient", "encounter", "dateWritten", "prescriber", "reasonCode", "reasonReference", "dateEnded", "reasonEnded", "note", "dosageInstruction", "dispenseRequest", "substitution", "priorPrescription" }) public class MedicationOrder extends DomainResource implements Equals2, HashCode2, ToString2 { protected List identifier; protected MedicationOrderStatus status; protected CodeableConcept medicationCodeableConcept; protected Reference medicationReference; protected Reference patient; protected Reference encounter; protected DateTime dateWritten; protected Reference prescriber; protected List reasonCode; protected List reasonReference; protected DateTime dateEnded; protected CodeableConcept reasonEnded; protected List note; protected List dosageInstruction; protected MedicationOrderDispenseRequest dispenseRequest; protected MedicationOrderSubstitution substitution; protected Reference priorPrescription; /** * Gets the value of the identifier property. * *

* This accessor method returns a reference to the live list, * not a snapshot. Therefore any modification you make to the * returned list will be present inside the JAXB object. * This is why there is not a set method for the identifier property. * *

* For example, to add a new item, do as follows: *

     *    getIdentifier().add(newItem);
     * 
* * *

* Objects of the following type(s) are allowed in the list * {@link Identifier } * * */ public List getIdentifier() { if (identifier == null) { identifier = new ArrayList(); } return this.identifier; } /** * Gets the value of the status property. * * @return * possible object is * {@link MedicationOrderStatus } * */ public MedicationOrderStatus getStatus() { return status; } /** * Sets the value of the status property. * * @param value * allowed object is * {@link MedicationOrderStatus } * */ public void setStatus(MedicationOrderStatus value) { this.status = value; } /** * Gets the value of the medicationCodeableConcept property. * * @return * possible object is * {@link CodeableConcept } * */ public CodeableConcept getMedicationCodeableConcept() { return medicationCodeableConcept; } /** * Sets the value of the medicationCodeableConcept property. * * @param value * allowed object is * {@link CodeableConcept } * */ public void setMedicationCodeableConcept(CodeableConcept value) { this.medicationCodeableConcept = value; } /** * Gets the value of the medicationReference property. * * @return * possible object is * {@link Reference } * */ public Reference getMedicationReference() { return medicationReference; } /** * Sets the value of the medicationReference property. * * @param value * allowed object is * {@link Reference } * */ public void setMedicationReference(Reference value) { this.medicationReference = value; } /** * Gets the value of the patient property. * * @return * possible object is * {@link Reference } * */ public Reference getPatient() { return patient; } /** * Sets the value of the patient property. * * @param value * allowed object is * {@link Reference } * */ public void setPatient(Reference value) { this.patient = value; } /** * Gets the value of the encounter property. * * @return * possible object is * {@link Reference } * */ public Reference getEncounter() { return encounter; } /** * Sets the value of the encounter property. * * @param value * allowed object is * {@link Reference } * */ public void setEncounter(Reference value) { this.encounter = value; } /** * Gets the value of the dateWritten property. * * @return * possible object is * {@link DateTime } * */ public DateTime getDateWritten() { return dateWritten; } /** * Sets the value of the dateWritten property. * * @param value * allowed object is * {@link DateTime } * */ public void setDateWritten(DateTime value) { this.dateWritten = value; } /** * Gets the value of the prescriber property. * * @return * possible object is * {@link Reference } * */ public Reference getPrescriber() { return prescriber; } /** * Sets the value of the prescriber property. * * @param value * allowed object is * {@link Reference } * */ public void setPrescriber(Reference value) { this.prescriber = value; } /** * Gets the value of the reasonCode property. * *

* This accessor method returns a reference to the live list, * not a snapshot. Therefore any modification you make to the * returned list will be present inside the JAXB object. * This is why there is not a set method for the reasonCode property. * *

* For example, to add a new item, do as follows: *

     *    getReasonCode().add(newItem);
     * 
* * *

* Objects of the following type(s) are allowed in the list * {@link CodeableConcept } * * */ public List getReasonCode() { if (reasonCode == null) { reasonCode = new ArrayList(); } return this.reasonCode; } /** * Gets the value of the reasonReference property. * *

* This accessor method returns a reference to the live list, * not a snapshot. Therefore any modification you make to the * returned list will be present inside the JAXB object. * This is why there is not a set method for the reasonReference property. * *

* For example, to add a new item, do as follows: *

     *    getReasonReference().add(newItem);
     * 
* * *

* Objects of the following type(s) are allowed in the list * {@link Reference } * * */ public List getReasonReference() { if (reasonReference == null) { reasonReference = new ArrayList(); } return this.reasonReference; } /** * Gets the value of the dateEnded property. * * @return * possible object is * {@link DateTime } * */ public DateTime getDateEnded() { return dateEnded; } /** * Sets the value of the dateEnded property. * * @param value * allowed object is * {@link DateTime } * */ public void setDateEnded(DateTime value) { this.dateEnded = value; } /** * Gets the value of the reasonEnded property. * * @return * possible object is * {@link CodeableConcept } * */ public CodeableConcept getReasonEnded() { return reasonEnded; } /** * Sets the value of the reasonEnded property. * * @param value * allowed object is * {@link CodeableConcept } * */ public void setReasonEnded(CodeableConcept value) { this.reasonEnded = value; } /** * Gets the value of the note property. * *

* This accessor method returns a reference to the live list, * not a snapshot. Therefore any modification you make to the * returned list will be present inside the JAXB object. * This is why there is not a set method for the note property. * *

* For example, to add a new item, do as follows: *

     *    getNote().add(newItem);
     * 
* * *

* Objects of the following type(s) are allowed in the list * {@link Annotation } * * */ public List getNote() { if (note == null) { note = new ArrayList(); } return this.note; } /** * Gets the value of the dosageInstruction property. * *

* This accessor method returns a reference to the live list, * not a snapshot. Therefore any modification you make to the * returned list will be present inside the JAXB object. * This is why there is not a set method for the dosageInstruction property. * *

* For example, to add a new item, do as follows: *

     *    getDosageInstruction().add(newItem);
     * 
* * *

* Objects of the following type(s) are allowed in the list * {@link MedicationOrderDosageInstruction } * * */ public List getDosageInstruction() { if (dosageInstruction == null) { dosageInstruction = new ArrayList(); } return this.dosageInstruction; } /** * Gets the value of the dispenseRequest property. * * @return * possible object is * {@link MedicationOrderDispenseRequest } * */ public MedicationOrderDispenseRequest getDispenseRequest() { return dispenseRequest; } /** * Sets the value of the dispenseRequest property. * * @param value * allowed object is * {@link MedicationOrderDispenseRequest } * */ public void setDispenseRequest(MedicationOrderDispenseRequest value) { this.dispenseRequest = value; } /** * Gets the value of the substitution property. * * @return * possible object is * {@link MedicationOrderSubstitution } * */ public MedicationOrderSubstitution getSubstitution() { return substitution; } /** * Sets the value of the substitution property. * * @param value * allowed object is * {@link MedicationOrderSubstitution } * */ public void setSubstitution(MedicationOrderSubstitution value) { this.substitution = value; } /** * Gets the value of the priorPrescription property. * * @return * possible object is * {@link Reference } * */ public Reference getPriorPrescription() { return priorPrescription; } /** * Sets the value of the priorPrescription property. * * @param value * allowed object is * {@link Reference } * */ public void setPriorPrescription(Reference value) { this.priorPrescription = value; } public MedicationOrder withIdentifier(Identifier... values) { if (values!= null) { for (Identifier value: values) { getIdentifier().add(value); } } return this; } public MedicationOrder withIdentifier(Collection values) { if (values!= null) { getIdentifier().addAll(values); } return this; } public MedicationOrder withStatus(MedicationOrderStatus value) { setStatus(value); return this; } public MedicationOrder withMedicationCodeableConcept(CodeableConcept value) { setMedicationCodeableConcept(value); return this; } public MedicationOrder withMedicationReference(Reference value) { setMedicationReference(value); return this; } public MedicationOrder withPatient(Reference value) { setPatient(value); return this; } public MedicationOrder withEncounter(Reference value) { setEncounter(value); return this; } public MedicationOrder withDateWritten(DateTime value) { setDateWritten(value); return this; } public MedicationOrder withPrescriber(Reference value) { setPrescriber(value); return this; } public MedicationOrder withReasonCode(CodeableConcept... values) { if (values!= null) { for (CodeableConcept value: values) { getReasonCode().add(value); } } return this; } public MedicationOrder withReasonCode(Collection values) { if (values!= null) { getReasonCode().addAll(values); } return this; } public MedicationOrder withReasonReference(Reference... values) { if (values!= null) { for (Reference value: values) { getReasonReference().add(value); } } return this; } public MedicationOrder withReasonReference(Collection values) { if (values!= null) { getReasonReference().addAll(values); } return this; } public MedicationOrder withDateEnded(DateTime value) { setDateEnded(value); return this; } public MedicationOrder withReasonEnded(CodeableConcept value) { setReasonEnded(value); return this; } public MedicationOrder withNote(Annotation... values) { if (values!= null) { for (Annotation value: values) { getNote().add(value); } } return this; } public MedicationOrder withNote(Collection values) { if (values!= null) { getNote().addAll(values); } return this; } public MedicationOrder withDosageInstruction(MedicationOrderDosageInstruction... values) { if (values!= null) { for (MedicationOrderDosageInstruction value: values) { getDosageInstruction().add(value); } } return this; } public MedicationOrder withDosageInstruction(Collection values) { if (values!= null) { getDosageInstruction().addAll(values); } return this; } public MedicationOrder withDispenseRequest(MedicationOrderDispenseRequest value) { setDispenseRequest(value); return this; } public MedicationOrder withSubstitution(MedicationOrderSubstitution value) { setSubstitution(value); return this; } public MedicationOrder withPriorPrescription(Reference value) { setPriorPrescription(value); return this; } @Override public MedicationOrder withText(Narrative value) { setText(value); return this; } @Override public MedicationOrder withContained(ResourceContainer... values) { if (values!= null) { for (ResourceContainer value: values) { getContained().add(value); } } return this; } @Override public MedicationOrder withContained(Collection values) { if (values!= null) { getContained().addAll(values); } return this; } @Override public MedicationOrder withExtension(Extension... values) { if (values!= null) { for (Extension value: values) { getExtension().add(value); } } return this; } @Override public MedicationOrder withExtension(Collection values) { if (values!= null) { getExtension().addAll(values); } return this; } @Override public MedicationOrder withModifierExtension(Extension... values) { if (values!= null) { for (Extension value: values) { getModifierExtension().add(value); } } return this; } @Override public MedicationOrder withModifierExtension(Collection values) { if (values!= null) { getModifierExtension().addAll(values); } return this; } @Override public MedicationOrder withId(Id value) { setId(value); return this; } @Override public MedicationOrder withMeta(Meta value) { setMeta(value); return this; } @Override public MedicationOrder withImplicitRules(Uri value) { setImplicitRules(value); return this; } @Override public MedicationOrder withLanguage(Code value) { setLanguage(value); return this; } @Override public boolean equals(ObjectLocator thisLocator, ObjectLocator thatLocator, Object object, EqualsStrategy2 strategy) { if ((object == null)||(this.getClass()!= object.getClass())) { return false; } if (this == object) { return true; } if (!super.equals(thisLocator, thatLocator, object, strategy)) { return false; } final MedicationOrder that = ((MedicationOrder) object); { List lhsIdentifier; lhsIdentifier = (((this.identifier!= null)&&(!this.identifier.isEmpty()))?this.getIdentifier():null); List rhsIdentifier; rhsIdentifier = (((that.identifier!= null)&&(!that.identifier.isEmpty()))?that.getIdentifier():null); if (!strategy.equals(LocatorUtils.property(thisLocator, "identifier", lhsIdentifier), LocatorUtils.property(thatLocator, "identifier", rhsIdentifier), lhsIdentifier, rhsIdentifier, ((this.identifier!= null)&&(!this.identifier.isEmpty())), ((that.identifier!= null)&&(!that.identifier.isEmpty())))) { return false; } } { MedicationOrderStatus lhsStatus; lhsStatus = this.getStatus(); MedicationOrderStatus rhsStatus; rhsStatus = that.getStatus(); if (!strategy.equals(LocatorUtils.property(thisLocator, "status", lhsStatus), LocatorUtils.property(thatLocator, "status", rhsStatus), lhsStatus, rhsStatus, (this.status!= null), (that.status!= null))) { return false; } } { CodeableConcept lhsMedicationCodeableConcept; lhsMedicationCodeableConcept = this.getMedicationCodeableConcept(); CodeableConcept rhsMedicationCodeableConcept; rhsMedicationCodeableConcept = that.getMedicationCodeableConcept(); if (!strategy.equals(LocatorUtils.property(thisLocator, "medicationCodeableConcept", lhsMedicationCodeableConcept), LocatorUtils.property(thatLocator, "medicationCodeableConcept", rhsMedicationCodeableConcept), lhsMedicationCodeableConcept, rhsMedicationCodeableConcept, (this.medicationCodeableConcept!= null), (that.medicationCodeableConcept!= null))) { return false; } } { Reference lhsMedicationReference; lhsMedicationReference = this.getMedicationReference(); Reference rhsMedicationReference; rhsMedicationReference = that.getMedicationReference(); if (!strategy.equals(LocatorUtils.property(thisLocator, "medicationReference", lhsMedicationReference), LocatorUtils.property(thatLocator, "medicationReference", rhsMedicationReference), lhsMedicationReference, rhsMedicationReference, (this.medicationReference!= null), (that.medicationReference!= null))) { return false; } } { Reference lhsPatient; lhsPatient = this.getPatient(); Reference rhsPatient; rhsPatient = that.getPatient(); if (!strategy.equals(LocatorUtils.property(thisLocator, "patient", lhsPatient), LocatorUtils.property(thatLocator, "patient", rhsPatient), lhsPatient, rhsPatient, (this.patient!= null), (that.patient!= null))) { return false; } } { Reference lhsEncounter; lhsEncounter = this.getEncounter(); Reference rhsEncounter; rhsEncounter = that.getEncounter(); if (!strategy.equals(LocatorUtils.property(thisLocator, "encounter", lhsEncounter), LocatorUtils.property(thatLocator, "encounter", rhsEncounter), lhsEncounter, rhsEncounter, (this.encounter!= null), (that.encounter!= null))) { return false; } } { DateTime lhsDateWritten; lhsDateWritten = this.getDateWritten(); DateTime rhsDateWritten; rhsDateWritten = that.getDateWritten(); if (!strategy.equals(LocatorUtils.property(thisLocator, "dateWritten", lhsDateWritten), LocatorUtils.property(thatLocator, "dateWritten", rhsDateWritten), lhsDateWritten, rhsDateWritten, (this.dateWritten!= null), (that.dateWritten!= null))) { return false; } } { Reference lhsPrescriber; lhsPrescriber = this.getPrescriber(); Reference rhsPrescriber; rhsPrescriber = that.getPrescriber(); if (!strategy.equals(LocatorUtils.property(thisLocator, "prescriber", lhsPrescriber), LocatorUtils.property(thatLocator, "prescriber", rhsPrescriber), lhsPrescriber, rhsPrescriber, (this.prescriber!= null), (that.prescriber!= null))) { return false; } } { List lhsReasonCode; lhsReasonCode = (((this.reasonCode!= null)&&(!this.reasonCode.isEmpty()))?this.getReasonCode():null); List rhsReasonCode; rhsReasonCode = (((that.reasonCode!= null)&&(!that.reasonCode.isEmpty()))?that.getReasonCode():null); if (!strategy.equals(LocatorUtils.property(thisLocator, "reasonCode", lhsReasonCode), LocatorUtils.property(thatLocator, "reasonCode", rhsReasonCode), lhsReasonCode, rhsReasonCode, ((this.reasonCode!= null)&&(!this.reasonCode.isEmpty())), ((that.reasonCode!= null)&&(!that.reasonCode.isEmpty())))) { return false; } } { List lhsReasonReference; lhsReasonReference = (((this.reasonReference!= null)&&(!this.reasonReference.isEmpty()))?this.getReasonReference():null); List rhsReasonReference; rhsReasonReference = (((that.reasonReference!= null)&&(!that.reasonReference.isEmpty()))?that.getReasonReference():null); if (!strategy.equals(LocatorUtils.property(thisLocator, "reasonReference", lhsReasonReference), LocatorUtils.property(thatLocator, "reasonReference", rhsReasonReference), lhsReasonReference, rhsReasonReference, ((this.reasonReference!= null)&&(!this.reasonReference.isEmpty())), ((that.reasonReference!= null)&&(!that.reasonReference.isEmpty())))) { return false; } } { DateTime lhsDateEnded; lhsDateEnded = this.getDateEnded(); DateTime rhsDateEnded; rhsDateEnded = that.getDateEnded(); if (!strategy.equals(LocatorUtils.property(thisLocator, "dateEnded", lhsDateEnded), LocatorUtils.property(thatLocator, "dateEnded", rhsDateEnded), lhsDateEnded, rhsDateEnded, (this.dateEnded!= null), (that.dateEnded!= null))) { return false; } } { CodeableConcept lhsReasonEnded; lhsReasonEnded = this.getReasonEnded(); CodeableConcept rhsReasonEnded; rhsReasonEnded = that.getReasonEnded(); if (!strategy.equals(LocatorUtils.property(thisLocator, "reasonEnded", lhsReasonEnded), LocatorUtils.property(thatLocator, "reasonEnded", rhsReasonEnded), lhsReasonEnded, rhsReasonEnded, (this.reasonEnded!= null), (that.reasonEnded!= null))) { return false; } } { List lhsNote; lhsNote = (((this.note!= null)&&(!this.note.isEmpty()))?this.getNote():null); List rhsNote; rhsNote = (((that.note!= null)&&(!that.note.isEmpty()))?that.getNote():null); if (!strategy.equals(LocatorUtils.property(thisLocator, "note", lhsNote), LocatorUtils.property(thatLocator, "note", rhsNote), lhsNote, rhsNote, ((this.note!= null)&&(!this.note.isEmpty())), ((that.note!= null)&&(!that.note.isEmpty())))) { return false; } } { List lhsDosageInstruction; lhsDosageInstruction = (((this.dosageInstruction!= null)&&(!this.dosageInstruction.isEmpty()))?this.getDosageInstruction():null); List rhsDosageInstruction; rhsDosageInstruction = (((that.dosageInstruction!= null)&&(!that.dosageInstruction.isEmpty()))?that.getDosageInstruction():null); if (!strategy.equals(LocatorUtils.property(thisLocator, "dosageInstruction", lhsDosageInstruction), LocatorUtils.property(thatLocator, "dosageInstruction", rhsDosageInstruction), lhsDosageInstruction, rhsDosageInstruction, ((this.dosageInstruction!= null)&&(!this.dosageInstruction.isEmpty())), ((that.dosageInstruction!= null)&&(!that.dosageInstruction.isEmpty())))) { return false; } } { MedicationOrderDispenseRequest lhsDispenseRequest; lhsDispenseRequest = this.getDispenseRequest(); MedicationOrderDispenseRequest rhsDispenseRequest; rhsDispenseRequest = that.getDispenseRequest(); if (!strategy.equals(LocatorUtils.property(thisLocator, "dispenseRequest", lhsDispenseRequest), LocatorUtils.property(thatLocator, "dispenseRequest", rhsDispenseRequest), lhsDispenseRequest, rhsDispenseRequest, (this.dispenseRequest!= null), (that.dispenseRequest!= null))) { return false; } } { MedicationOrderSubstitution lhsSubstitution; lhsSubstitution = this.getSubstitution(); MedicationOrderSubstitution rhsSubstitution; rhsSubstitution = that.getSubstitution(); if (!strategy.equals(LocatorUtils.property(thisLocator, "substitution", lhsSubstitution), LocatorUtils.property(thatLocator, "substitution", rhsSubstitution), lhsSubstitution, rhsSubstitution, (this.substitution!= null), (that.substitution!= null))) { return false; } } { Reference lhsPriorPrescription; lhsPriorPrescription = this.getPriorPrescription(); Reference rhsPriorPrescription; rhsPriorPrescription = that.getPriorPrescription(); if (!strategy.equals(LocatorUtils.property(thisLocator, "priorPrescription", lhsPriorPrescription), LocatorUtils.property(thatLocator, "priorPrescription", rhsPriorPrescription), lhsPriorPrescription, rhsPriorPrescription, (this.priorPrescription!= null), (that.priorPrescription!= null))) { return false; } } return true; } @Override public boolean equals(Object object) { final EqualsStrategy2 strategy = JAXBEqualsStrategy.getInstance(); return equals(null, null, object, strategy); } @Override public int hashCode(ObjectLocator locator, HashCodeStrategy2 strategy) { int currentHashCode = super.hashCode(locator, strategy); { List theIdentifier; theIdentifier = (((this.identifier!= null)&&(!this.identifier.isEmpty()))?this.getIdentifier():null); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "identifier", theIdentifier), currentHashCode, theIdentifier, ((this.identifier!= null)&&(!this.identifier.isEmpty()))); } { MedicationOrderStatus theStatus; theStatus = this.getStatus(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "status", theStatus), currentHashCode, theStatus, (this.status!= null)); } { CodeableConcept theMedicationCodeableConcept; theMedicationCodeableConcept = this.getMedicationCodeableConcept(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "medicationCodeableConcept", theMedicationCodeableConcept), currentHashCode, theMedicationCodeableConcept, (this.medicationCodeableConcept!= null)); } { Reference theMedicationReference; theMedicationReference = this.getMedicationReference(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "medicationReference", theMedicationReference), currentHashCode, theMedicationReference, (this.medicationReference!= null)); } { Reference thePatient; thePatient = this.getPatient(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "patient", thePatient), currentHashCode, thePatient, (this.patient!= null)); } { Reference theEncounter; theEncounter = this.getEncounter(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "encounter", theEncounter), currentHashCode, theEncounter, (this.encounter!= null)); } { DateTime theDateWritten; theDateWritten = this.getDateWritten(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "dateWritten", theDateWritten), currentHashCode, theDateWritten, (this.dateWritten!= null)); } { Reference thePrescriber; thePrescriber = this.getPrescriber(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "prescriber", thePrescriber), currentHashCode, thePrescriber, (this.prescriber!= null)); } { List theReasonCode; theReasonCode = (((this.reasonCode!= null)&&(!this.reasonCode.isEmpty()))?this.getReasonCode():null); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "reasonCode", theReasonCode), currentHashCode, theReasonCode, ((this.reasonCode!= null)&&(!this.reasonCode.isEmpty()))); } { List theReasonReference; theReasonReference = (((this.reasonReference!= null)&&(!this.reasonReference.isEmpty()))?this.getReasonReference():null); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "reasonReference", theReasonReference), currentHashCode, theReasonReference, ((this.reasonReference!= null)&&(!this.reasonReference.isEmpty()))); } { DateTime theDateEnded; theDateEnded = this.getDateEnded(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "dateEnded", theDateEnded), currentHashCode, theDateEnded, (this.dateEnded!= null)); } { CodeableConcept theReasonEnded; theReasonEnded = this.getReasonEnded(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "reasonEnded", theReasonEnded), currentHashCode, theReasonEnded, (this.reasonEnded!= null)); } { List theNote; theNote = (((this.note!= null)&&(!this.note.isEmpty()))?this.getNote():null); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "note", theNote), currentHashCode, theNote, ((this.note!= null)&&(!this.note.isEmpty()))); } { List theDosageInstruction; theDosageInstruction = (((this.dosageInstruction!= null)&&(!this.dosageInstruction.isEmpty()))?this.getDosageInstruction():null); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "dosageInstruction", theDosageInstruction), currentHashCode, theDosageInstruction, ((this.dosageInstruction!= null)&&(!this.dosageInstruction.isEmpty()))); } { MedicationOrderDispenseRequest theDispenseRequest; theDispenseRequest = this.getDispenseRequest(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "dispenseRequest", theDispenseRequest), currentHashCode, theDispenseRequest, (this.dispenseRequest!= null)); } { MedicationOrderSubstitution theSubstitution; theSubstitution = this.getSubstitution(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "substitution", theSubstitution), currentHashCode, theSubstitution, (this.substitution!= null)); } { Reference thePriorPrescription; thePriorPrescription = this.getPriorPrescription(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "priorPrescription", thePriorPrescription), currentHashCode, thePriorPrescription, (this.priorPrescription!= null)); } return currentHashCode; } @Override public int hashCode() { final HashCodeStrategy2 strategy = JAXBHashCodeStrategy.getInstance(); return this.hashCode(null, strategy); } @Override public java.lang.String toString() { final ToStringStrategy2 strategy = JAXBToStringStrategy.getInstance(); final StringBuilder buffer = new StringBuilder(); append(null, buffer, strategy); return buffer.toString(); } @Override public StringBuilder append(ObjectLocator locator, StringBuilder buffer, ToStringStrategy2 strategy) { strategy.appendStart(locator, this, buffer); appendFields(locator, buffer, strategy); strategy.appendEnd(locator, this, buffer); return buffer; } @Override public StringBuilder appendFields(ObjectLocator locator, StringBuilder buffer, ToStringStrategy2 strategy) { super.appendFields(locator, buffer, strategy); { List theIdentifier; theIdentifier = (((this.identifier!= null)&&(!this.identifier.isEmpty()))?this.getIdentifier():null); strategy.appendField(locator, this, "identifier", buffer, theIdentifier, ((this.identifier!= null)&&(!this.identifier.isEmpty()))); } { MedicationOrderStatus theStatus; theStatus = this.getStatus(); strategy.appendField(locator, this, "status", buffer, theStatus, (this.status!= null)); } { CodeableConcept theMedicationCodeableConcept; theMedicationCodeableConcept = this.getMedicationCodeableConcept(); strategy.appendField(locator, this, "medicationCodeableConcept", buffer, theMedicationCodeableConcept, (this.medicationCodeableConcept!= null)); } { Reference theMedicationReference; theMedicationReference = this.getMedicationReference(); strategy.appendField(locator, this, "medicationReference", buffer, theMedicationReference, (this.medicationReference!= null)); } { Reference thePatient; thePatient = this.getPatient(); strategy.appendField(locator, this, "patient", buffer, thePatient, (this.patient!= null)); } { Reference theEncounter; theEncounter = this.getEncounter(); strategy.appendField(locator, this, "encounter", buffer, theEncounter, (this.encounter!= null)); } { DateTime theDateWritten; theDateWritten = this.getDateWritten(); strategy.appendField(locator, this, "dateWritten", buffer, theDateWritten, (this.dateWritten!= null)); } { Reference thePrescriber; thePrescriber = this.getPrescriber(); strategy.appendField(locator, this, "prescriber", buffer, thePrescriber, (this.prescriber!= null)); } { List theReasonCode; theReasonCode = (((this.reasonCode!= null)&&(!this.reasonCode.isEmpty()))?this.getReasonCode():null); strategy.appendField(locator, this, "reasonCode", buffer, theReasonCode, ((this.reasonCode!= null)&&(!this.reasonCode.isEmpty()))); } { List theReasonReference; theReasonReference = (((this.reasonReference!= null)&&(!this.reasonReference.isEmpty()))?this.getReasonReference():null); strategy.appendField(locator, this, "reasonReference", buffer, theReasonReference, ((this.reasonReference!= null)&&(!this.reasonReference.isEmpty()))); } { DateTime theDateEnded; theDateEnded = this.getDateEnded(); strategy.appendField(locator, this, "dateEnded", buffer, theDateEnded, (this.dateEnded!= null)); } { CodeableConcept theReasonEnded; theReasonEnded = this.getReasonEnded(); strategy.appendField(locator, this, "reasonEnded", buffer, theReasonEnded, (this.reasonEnded!= null)); } { List theNote; theNote = (((this.note!= null)&&(!this.note.isEmpty()))?this.getNote():null); strategy.appendField(locator, this, "note", buffer, theNote, ((this.note!= null)&&(!this.note.isEmpty()))); } { List theDosageInstruction; theDosageInstruction = (((this.dosageInstruction!= null)&&(!this.dosageInstruction.isEmpty()))?this.getDosageInstruction():null); strategy.appendField(locator, this, "dosageInstruction", buffer, theDosageInstruction, ((this.dosageInstruction!= null)&&(!this.dosageInstruction.isEmpty()))); } { MedicationOrderDispenseRequest theDispenseRequest; theDispenseRequest = this.getDispenseRequest(); strategy.appendField(locator, this, "dispenseRequest", buffer, theDispenseRequest, (this.dispenseRequest!= null)); } { MedicationOrderSubstitution theSubstitution; theSubstitution = this.getSubstitution(); strategy.appendField(locator, this, "substitution", buffer, theSubstitution, (this.substitution!= null)); } { Reference thePriorPrescription; thePriorPrescription = this.getPriorPrescription(); strategy.appendField(locator, this, "priorPrescription", buffer, thePriorPrescription, (this.priorPrescription!= null)); } return buffer; } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy