org.hl7.fhir.TriggerDefinition Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of quick Show documentation
Show all versions of quick Show documentation
The quick 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.03.21 at 12:42:34 PM MDT
//
package org.hl7.fhir;
import java.util.Collection;
import jakarta.xml.bind.annotation.XmlAccessType;
import jakarta.xml.bind.annotation.XmlAccessorType;
import jakarta.xml.bind.annotation.XmlElement;
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;
/**
* If the element is present, it must have a value for at least one of the defined elements, an @id referenced from the Narrative, or extensions
*
* Java class for TriggerDefinition complex type.
*
*
The following schema fragment specifies the expected content contained within this class.
*
*
* <complexType name="TriggerDefinition">
* <complexContent>
* <extension base="{http://hl7.org/fhir}Element">
* <sequence>
* <element name="type" type="{http://hl7.org/fhir}TriggerType"/>
* <element name="eventName" type="{http://hl7.org/fhir}string" minOccurs="0"/>
* <choice minOccurs="0">
* <element name="eventTimingTiming" type="{http://hl7.org/fhir}Timing"/>
* <element name="eventTimingReference" type="{http://hl7.org/fhir}Reference"/>
* <element name="eventTimingDate" type="{http://hl7.org/fhir}date"/>
* <element name="eventTimingDateTime" type="{http://hl7.org/fhir}dateTime"/>
* </choice>
* <element name="eventData" type="{http://hl7.org/fhir}DataRequirement" minOccurs="0"/>
* </sequence>
* </extension>
* </complexContent>
* </complexType>
*
*
*
*/
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "TriggerDefinition", propOrder = {
"type",
"eventName",
"eventTimingTiming",
"eventTimingReference",
"eventTimingDate",
"eventTimingDateTime",
"eventData"
})
public class TriggerDefinition
extends Element
implements Equals2, HashCode2, ToString2
{
@XmlElement(required = true)
protected TriggerType type;
protected org.hl7.fhir.String eventName;
protected Timing eventTimingTiming;
protected Reference eventTimingReference;
protected Date eventTimingDate;
protected DateTime eventTimingDateTime;
protected DataRequirement eventData;
/**
* Gets the value of the type property.
*
* @return
* possible object is
* {@link TriggerType }
*
*/
public TriggerType getType() {
return type;
}
/**
* Sets the value of the type property.
*
* @param value
* allowed object is
* {@link TriggerType }
*
*/
public void setType(TriggerType value) {
this.type = value;
}
/**
* Gets the value of the eventName property.
*
* @return
* possible object is
* {@link org.hl7.fhir.String }
*
*/
public org.hl7.fhir.String getEventName() {
return eventName;
}
/**
* Sets the value of the eventName property.
*
* @param value
* allowed object is
* {@link org.hl7.fhir.String }
*
*/
public void setEventName(org.hl7.fhir.String value) {
this.eventName = value;
}
/**
* Gets the value of the eventTimingTiming property.
*
* @return
* possible object is
* {@link Timing }
*
*/
public Timing getEventTimingTiming() {
return eventTimingTiming;
}
/**
* Sets the value of the eventTimingTiming property.
*
* @param value
* allowed object is
* {@link Timing }
*
*/
public void setEventTimingTiming(Timing value) {
this.eventTimingTiming = value;
}
/**
* Gets the value of the eventTimingReference property.
*
* @return
* possible object is
* {@link Reference }
*
*/
public Reference getEventTimingReference() {
return eventTimingReference;
}
/**
* Sets the value of the eventTimingReference property.
*
* @param value
* allowed object is
* {@link Reference }
*
*/
public void setEventTimingReference(Reference value) {
this.eventTimingReference = value;
}
/**
* Gets the value of the eventTimingDate property.
*
* @return
* possible object is
* {@link Date }
*
*/
public Date getEventTimingDate() {
return eventTimingDate;
}
/**
* Sets the value of the eventTimingDate property.
*
* @param value
* allowed object is
* {@link Date }
*
*/
public void setEventTimingDate(Date value) {
this.eventTimingDate = value;
}
/**
* Gets the value of the eventTimingDateTime property.
*
* @return
* possible object is
* {@link DateTime }
*
*/
public DateTime getEventTimingDateTime() {
return eventTimingDateTime;
}
/**
* Sets the value of the eventTimingDateTime property.
*
* @param value
* allowed object is
* {@link DateTime }
*
*/
public void setEventTimingDateTime(DateTime value) {
this.eventTimingDateTime = value;
}
/**
* Gets the value of the eventData property.
*
* @return
* possible object is
* {@link DataRequirement }
*
*/
public DataRequirement getEventData() {
return eventData;
}
/**
* Sets the value of the eventData property.
*
* @param value
* allowed object is
* {@link DataRequirement }
*
*/
public void setEventData(DataRequirement value) {
this.eventData = value;
}
public TriggerDefinition withType(TriggerType value) {
setType(value);
return this;
}
public TriggerDefinition withEventName(org.hl7.fhir.String value) {
setEventName(value);
return this;
}
public TriggerDefinition withEventTimingTiming(Timing value) {
setEventTimingTiming(value);
return this;
}
public TriggerDefinition withEventTimingReference(Reference value) {
setEventTimingReference(value);
return this;
}
public TriggerDefinition withEventTimingDate(Date value) {
setEventTimingDate(value);
return this;
}
public TriggerDefinition withEventTimingDateTime(DateTime value) {
setEventTimingDateTime(value);
return this;
}
public TriggerDefinition withEventData(DataRequirement value) {
setEventData(value);
return this;
}
@Override
public TriggerDefinition withExtension(Extension... values) {
if (values!= null) {
for (Extension value: values) {
getExtension().add(value);
}
}
return this;
}
@Override
public TriggerDefinition withExtension(Collection values) {
if (values!= null) {
getExtension().addAll(values);
}
return this;
}
@Override
public TriggerDefinition withId(java.lang.String value) {
setId(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 TriggerDefinition that = ((TriggerDefinition) object);
{
TriggerType lhsType;
lhsType = this.getType();
TriggerType rhsType;
rhsType = that.getType();
if (!strategy.equals(LocatorUtils.property(thisLocator, "type", lhsType), LocatorUtils.property(thatLocator, "type", rhsType), lhsType, rhsType, (this.type!= null), (that.type!= null))) {
return false;
}
}
{
org.hl7.fhir.String lhsEventName;
lhsEventName = this.getEventName();
org.hl7.fhir.String rhsEventName;
rhsEventName = that.getEventName();
if (!strategy.equals(LocatorUtils.property(thisLocator, "eventName", lhsEventName), LocatorUtils.property(thatLocator, "eventName", rhsEventName), lhsEventName, rhsEventName, (this.eventName!= null), (that.eventName!= null))) {
return false;
}
}
{
Timing lhsEventTimingTiming;
lhsEventTimingTiming = this.getEventTimingTiming();
Timing rhsEventTimingTiming;
rhsEventTimingTiming = that.getEventTimingTiming();
if (!strategy.equals(LocatorUtils.property(thisLocator, "eventTimingTiming", lhsEventTimingTiming), LocatorUtils.property(thatLocator, "eventTimingTiming", rhsEventTimingTiming), lhsEventTimingTiming, rhsEventTimingTiming, (this.eventTimingTiming!= null), (that.eventTimingTiming!= null))) {
return false;
}
}
{
Reference lhsEventTimingReference;
lhsEventTimingReference = this.getEventTimingReference();
Reference rhsEventTimingReference;
rhsEventTimingReference = that.getEventTimingReference();
if (!strategy.equals(LocatorUtils.property(thisLocator, "eventTimingReference", lhsEventTimingReference), LocatorUtils.property(thatLocator, "eventTimingReference", rhsEventTimingReference), lhsEventTimingReference, rhsEventTimingReference, (this.eventTimingReference!= null), (that.eventTimingReference!= null))) {
return false;
}
}
{
Date lhsEventTimingDate;
lhsEventTimingDate = this.getEventTimingDate();
Date rhsEventTimingDate;
rhsEventTimingDate = that.getEventTimingDate();
if (!strategy.equals(LocatorUtils.property(thisLocator, "eventTimingDate", lhsEventTimingDate), LocatorUtils.property(thatLocator, "eventTimingDate", rhsEventTimingDate), lhsEventTimingDate, rhsEventTimingDate, (this.eventTimingDate!= null), (that.eventTimingDate!= null))) {
return false;
}
}
{
DateTime lhsEventTimingDateTime;
lhsEventTimingDateTime = this.getEventTimingDateTime();
DateTime rhsEventTimingDateTime;
rhsEventTimingDateTime = that.getEventTimingDateTime();
if (!strategy.equals(LocatorUtils.property(thisLocator, "eventTimingDateTime", lhsEventTimingDateTime), LocatorUtils.property(thatLocator, "eventTimingDateTime", rhsEventTimingDateTime), lhsEventTimingDateTime, rhsEventTimingDateTime, (this.eventTimingDateTime!= null), (that.eventTimingDateTime!= null))) {
return false;
}
}
{
DataRequirement lhsEventData;
lhsEventData = this.getEventData();
DataRequirement rhsEventData;
rhsEventData = that.getEventData();
if (!strategy.equals(LocatorUtils.property(thisLocator, "eventData", lhsEventData), LocatorUtils.property(thatLocator, "eventData", rhsEventData), lhsEventData, rhsEventData, (this.eventData!= null), (that.eventData!= 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);
{
TriggerType theType;
theType = this.getType();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "type", theType), currentHashCode, theType, (this.type!= null));
}
{
org.hl7.fhir.String theEventName;
theEventName = this.getEventName();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "eventName", theEventName), currentHashCode, theEventName, (this.eventName!= null));
}
{
Timing theEventTimingTiming;
theEventTimingTiming = this.getEventTimingTiming();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "eventTimingTiming", theEventTimingTiming), currentHashCode, theEventTimingTiming, (this.eventTimingTiming!= null));
}
{
Reference theEventTimingReference;
theEventTimingReference = this.getEventTimingReference();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "eventTimingReference", theEventTimingReference), currentHashCode, theEventTimingReference, (this.eventTimingReference!= null));
}
{
Date theEventTimingDate;
theEventTimingDate = this.getEventTimingDate();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "eventTimingDate", theEventTimingDate), currentHashCode, theEventTimingDate, (this.eventTimingDate!= null));
}
{
DateTime theEventTimingDateTime;
theEventTimingDateTime = this.getEventTimingDateTime();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "eventTimingDateTime", theEventTimingDateTime), currentHashCode, theEventTimingDateTime, (this.eventTimingDateTime!= null));
}
{
DataRequirement theEventData;
theEventData = this.getEventData();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "eventData", theEventData), currentHashCode, theEventData, (this.eventData!= 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);
{
TriggerType theType;
theType = this.getType();
strategy.appendField(locator, this, "type", buffer, theType, (this.type!= null));
}
{
org.hl7.fhir.String theEventName;
theEventName = this.getEventName();
strategy.appendField(locator, this, "eventName", buffer, theEventName, (this.eventName!= null));
}
{
Timing theEventTimingTiming;
theEventTimingTiming = this.getEventTimingTiming();
strategy.appendField(locator, this, "eventTimingTiming", buffer, theEventTimingTiming, (this.eventTimingTiming!= null));
}
{
Reference theEventTimingReference;
theEventTimingReference = this.getEventTimingReference();
strategy.appendField(locator, this, "eventTimingReference", buffer, theEventTimingReference, (this.eventTimingReference!= null));
}
{
Date theEventTimingDate;
theEventTimingDate = this.getEventTimingDate();
strategy.appendField(locator, this, "eventTimingDate", buffer, theEventTimingDate, (this.eventTimingDate!= null));
}
{
DateTime theEventTimingDateTime;
theEventTimingDateTime = this.getEventTimingDateTime();
strategy.appendField(locator, this, "eventTimingDateTime", buffer, theEventTimingDateTime, (this.eventTimingDateTime!= null));
}
{
DataRequirement theEventData;
theEventData = this.getEventData();
strategy.appendField(locator, this, "eventData", buffer, theEventData, (this.eventData!= null));
}
return buffer;
}
}