gov.healthit.qdm.v4_2.MedicationAdverseEffects Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of qdm Show documentation
Show all versions of qdm Show documentation
The qdm library for the Clinical Quality Language Java reference implementation
//
// This file was generated by the Eclipse Implementation of JAXB, v3.0.2
// See https://eclipse-ee4j.github.io/jaxb-ri
// Any modifications to this file will be lost upon recompilation of the source schema.
// Generated on: 2024.09.27 at 11:16:11 AM MDT
//
package gov.healthit.qdm.v4_2;
import javax.xml.datatype.XMLGregorianCalendar;
import jakarta.xml.bind.annotation.XmlAccessType;
import jakarta.xml.bind.annotation.XmlAccessorType;
import jakarta.xml.bind.annotation.XmlSchemaType;
import jakarta.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;
/**
*
* Data elements that meet criteria using this
* datatype should document an
* unexpected or dangerous reaction to the
* medication indicated by the
* QDM category and its corresponding value
* set.
*
*
* Java class for MedicationAdverseEffects complex type.
*
*
The following schema fragment specifies the expected content contained within this class.
*
*
* <complexType name="MedicationAdverseEffects">
* <complexContent>
* <extension base="{urn:healthit-gov:qdm:v4_2}QDMBaseType">
* <sequence>
* <element name="startDatetime" type="{http://www.w3.org/2001/XMLSchema}dateTime" minOccurs="0"/>
* <element name="stopDatetime" type="{http://www.w3.org/2001/XMLSchema}dateTime" minOccurs="0"/>
* <element name="reaction" type="{urn:healthit-gov:qdm:v4_2}Concept" minOccurs="0"/>
* </sequence>
* </extension>
* </complexContent>
* </complexType>
*
*
*
*/
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "MedicationAdverseEffects", propOrder = {
"startDatetime",
"stopDatetime",
"reaction"
})
public class MedicationAdverseEffects
extends QDMBaseType
implements Equals2, HashCode2, ToString2
{
@XmlSchemaType(name = "dateTime")
protected XMLGregorianCalendar startDatetime;
@XmlSchemaType(name = "dateTime")
protected XMLGregorianCalendar stopDatetime;
protected Concept reaction;
/**
* Gets the value of the startDatetime property.
*
* @return
* possible object is
* {@link XMLGregorianCalendar }
*
*/
public XMLGregorianCalendar getStartDatetime() {
return startDatetime;
}
/**
* Sets the value of the startDatetime property.
*
* @param value
* allowed object is
* {@link XMLGregorianCalendar }
*
*/
public void setStartDatetime(XMLGregorianCalendar value) {
this.startDatetime = value;
}
/**
* Gets the value of the stopDatetime property.
*
* @return
* possible object is
* {@link XMLGregorianCalendar }
*
*/
public XMLGregorianCalendar getStopDatetime() {
return stopDatetime;
}
/**
* Sets the value of the stopDatetime property.
*
* @param value
* allowed object is
* {@link XMLGregorianCalendar }
*
*/
public void setStopDatetime(XMLGregorianCalendar value) {
this.stopDatetime = value;
}
/**
* Gets the value of the reaction property.
*
* @return
* possible object is
* {@link Concept }
*
*/
public Concept getReaction() {
return reaction;
}
/**
* Sets the value of the reaction property.
*
* @param value
* allowed object is
* {@link Concept }
*
*/
public void setReaction(Concept value) {
this.reaction = value;
}
public MedicationAdverseEffects withStartDatetime(XMLGregorianCalendar value) {
setStartDatetime(value);
return this;
}
public MedicationAdverseEffects withStopDatetime(XMLGregorianCalendar value) {
setStopDatetime(value);
return this;
}
public MedicationAdverseEffects withReaction(Concept value) {
setReaction(value);
return this;
}
@Override
public MedicationAdverseEffects withCode(Concept value) {
setCode(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 MedicationAdverseEffects that = ((MedicationAdverseEffects) object);
{
XMLGregorianCalendar lhsStartDatetime;
lhsStartDatetime = this.getStartDatetime();
XMLGregorianCalendar rhsStartDatetime;
rhsStartDatetime = that.getStartDatetime();
if (!strategy.equals(LocatorUtils.property(thisLocator, "startDatetime", lhsStartDatetime), LocatorUtils.property(thatLocator, "startDatetime", rhsStartDatetime), lhsStartDatetime, rhsStartDatetime, (this.startDatetime!= null), (that.startDatetime!= null))) {
return false;
}
}
{
XMLGregorianCalendar lhsStopDatetime;
lhsStopDatetime = this.getStopDatetime();
XMLGregorianCalendar rhsStopDatetime;
rhsStopDatetime = that.getStopDatetime();
if (!strategy.equals(LocatorUtils.property(thisLocator, "stopDatetime", lhsStopDatetime), LocatorUtils.property(thatLocator, "stopDatetime", rhsStopDatetime), lhsStopDatetime, rhsStopDatetime, (this.stopDatetime!= null), (that.stopDatetime!= null))) {
return false;
}
}
{
Concept lhsReaction;
lhsReaction = this.getReaction();
Concept rhsReaction;
rhsReaction = that.getReaction();
if (!strategy.equals(LocatorUtils.property(thisLocator, "reaction", lhsReaction), LocatorUtils.property(thatLocator, "reaction", rhsReaction), lhsReaction, rhsReaction, (this.reaction!= null), (that.reaction!= 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);
{
XMLGregorianCalendar theStartDatetime;
theStartDatetime = this.getStartDatetime();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "startDatetime", theStartDatetime), currentHashCode, theStartDatetime, (this.startDatetime!= null));
}
{
XMLGregorianCalendar theStopDatetime;
theStopDatetime = this.getStopDatetime();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "stopDatetime", theStopDatetime), currentHashCode, theStopDatetime, (this.stopDatetime!= null));
}
{
Concept theReaction;
theReaction = this.getReaction();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "reaction", theReaction), currentHashCode, theReaction, (this.reaction!= null));
}
return currentHashCode;
}
@Override
public int hashCode() {
final HashCodeStrategy2 strategy = JAXBHashCodeStrategy.getInstance();
return this.hashCode(null, strategy);
}
@Override
public 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);
{
XMLGregorianCalendar theStartDatetime;
theStartDatetime = this.getStartDatetime();
strategy.appendField(locator, this, "startDatetime", buffer, theStartDatetime, (this.startDatetime!= null));
}
{
XMLGregorianCalendar theStopDatetime;
theStopDatetime = this.getStopDatetime();
strategy.appendField(locator, this, "stopDatetime", buffer, theStopDatetime, (this.stopDatetime!= null));
}
{
Concept theReaction;
theReaction = this.getReaction();
strategy.appendField(locator, this, "reaction", buffer, theReaction, (this.reaction!= null));
}
return buffer;
}
}