org.hl7.fhir.SampledData 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 SampledData complex type.
*
*
The following schema fragment specifies the expected content contained within this class.
*
*
* <complexType name="SampledData">
* <complexContent>
* <extension base="{http://hl7.org/fhir}Element">
* <sequence>
* <element name="origin" type="{http://hl7.org/fhir}SimpleQuantity"/>
* <element name="period" type="{http://hl7.org/fhir}decimal"/>
* <element name="factor" type="{http://hl7.org/fhir}decimal" minOccurs="0"/>
* <element name="lowerLimit" type="{http://hl7.org/fhir}decimal" minOccurs="0"/>
* <element name="upperLimit" type="{http://hl7.org/fhir}decimal" minOccurs="0"/>
* <element name="dimensions" type="{http://hl7.org/fhir}positiveInt"/>
* <element name="data" type="{http://hl7.org/fhir}SampledDataDataType"/>
* </sequence>
* </extension>
* </complexContent>
* </complexType>
*
*
*
*/
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "SampledData", propOrder = {
"origin",
"period",
"factor",
"lowerLimit",
"upperLimit",
"dimensions",
"data"
})
public class SampledData
extends Element
implements Equals2, HashCode2, ToString2
{
@XmlElement(required = true)
protected SimpleQuantity origin;
@XmlElement(required = true)
protected Decimal period;
protected Decimal factor;
protected Decimal lowerLimit;
protected Decimal upperLimit;
@XmlElement(required = true)
protected PositiveInt dimensions;
@XmlElement(required = true)
protected SampledDataDataType data;
/**
* Gets the value of the origin property.
*
* @return
* possible object is
* {@link SimpleQuantity }
*
*/
public SimpleQuantity getOrigin() {
return origin;
}
/**
* Sets the value of the origin property.
*
* @param value
* allowed object is
* {@link SimpleQuantity }
*
*/
public void setOrigin(SimpleQuantity value) {
this.origin = value;
}
/**
* Gets the value of the period property.
*
* @return
* possible object is
* {@link Decimal }
*
*/
public Decimal getPeriod() {
return period;
}
/**
* Sets the value of the period property.
*
* @param value
* allowed object is
* {@link Decimal }
*
*/
public void setPeriod(Decimal value) {
this.period = value;
}
/**
* Gets the value of the factor property.
*
* @return
* possible object is
* {@link Decimal }
*
*/
public Decimal getFactor() {
return factor;
}
/**
* Sets the value of the factor property.
*
* @param value
* allowed object is
* {@link Decimal }
*
*/
public void setFactor(Decimal value) {
this.factor = value;
}
/**
* Gets the value of the lowerLimit property.
*
* @return
* possible object is
* {@link Decimal }
*
*/
public Decimal getLowerLimit() {
return lowerLimit;
}
/**
* Sets the value of the lowerLimit property.
*
* @param value
* allowed object is
* {@link Decimal }
*
*/
public void setLowerLimit(Decimal value) {
this.lowerLimit = value;
}
/**
* Gets the value of the upperLimit property.
*
* @return
* possible object is
* {@link Decimal }
*
*/
public Decimal getUpperLimit() {
return upperLimit;
}
/**
* Sets the value of the upperLimit property.
*
* @param value
* allowed object is
* {@link Decimal }
*
*/
public void setUpperLimit(Decimal value) {
this.upperLimit = value;
}
/**
* Gets the value of the dimensions property.
*
* @return
* possible object is
* {@link PositiveInt }
*
*/
public PositiveInt getDimensions() {
return dimensions;
}
/**
* Sets the value of the dimensions property.
*
* @param value
* allowed object is
* {@link PositiveInt }
*
*/
public void setDimensions(PositiveInt value) {
this.dimensions = value;
}
/**
* Gets the value of the data property.
*
* @return
* possible object is
* {@link SampledDataDataType }
*
*/
public SampledDataDataType getData() {
return data;
}
/**
* Sets the value of the data property.
*
* @param value
* allowed object is
* {@link SampledDataDataType }
*
*/
public void setData(SampledDataDataType value) {
this.data = value;
}
public SampledData withOrigin(SimpleQuantity value) {
setOrigin(value);
return this;
}
public SampledData withPeriod(Decimal value) {
setPeriod(value);
return this;
}
public SampledData withFactor(Decimal value) {
setFactor(value);
return this;
}
public SampledData withLowerLimit(Decimal value) {
setLowerLimit(value);
return this;
}
public SampledData withUpperLimit(Decimal value) {
setUpperLimit(value);
return this;
}
public SampledData withDimensions(PositiveInt value) {
setDimensions(value);
return this;
}
public SampledData withData(SampledDataDataType value) {
setData(value);
return this;
}
@Override
public SampledData withExtension(Extension... values) {
if (values!= null) {
for (Extension value: values) {
getExtension().add(value);
}
}
return this;
}
@Override
public SampledData withExtension(Collection values) {
if (values!= null) {
getExtension().addAll(values);
}
return this;
}
@Override
public SampledData 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 SampledData that = ((SampledData) object);
{
SimpleQuantity lhsOrigin;
lhsOrigin = this.getOrigin();
SimpleQuantity rhsOrigin;
rhsOrigin = that.getOrigin();
if (!strategy.equals(LocatorUtils.property(thisLocator, "origin", lhsOrigin), LocatorUtils.property(thatLocator, "origin", rhsOrigin), lhsOrigin, rhsOrigin, (this.origin!= null), (that.origin!= null))) {
return false;
}
}
{
Decimal lhsPeriod;
lhsPeriod = this.getPeriod();
Decimal rhsPeriod;
rhsPeriod = that.getPeriod();
if (!strategy.equals(LocatorUtils.property(thisLocator, "period", lhsPeriod), LocatorUtils.property(thatLocator, "period", rhsPeriod), lhsPeriod, rhsPeriod, (this.period!= null), (that.period!= null))) {
return false;
}
}
{
Decimal lhsFactor;
lhsFactor = this.getFactor();
Decimal rhsFactor;
rhsFactor = that.getFactor();
if (!strategy.equals(LocatorUtils.property(thisLocator, "factor", lhsFactor), LocatorUtils.property(thatLocator, "factor", rhsFactor), lhsFactor, rhsFactor, (this.factor!= null), (that.factor!= null))) {
return false;
}
}
{
Decimal lhsLowerLimit;
lhsLowerLimit = this.getLowerLimit();
Decimal rhsLowerLimit;
rhsLowerLimit = that.getLowerLimit();
if (!strategy.equals(LocatorUtils.property(thisLocator, "lowerLimit", lhsLowerLimit), LocatorUtils.property(thatLocator, "lowerLimit", rhsLowerLimit), lhsLowerLimit, rhsLowerLimit, (this.lowerLimit!= null), (that.lowerLimit!= null))) {
return false;
}
}
{
Decimal lhsUpperLimit;
lhsUpperLimit = this.getUpperLimit();
Decimal rhsUpperLimit;
rhsUpperLimit = that.getUpperLimit();
if (!strategy.equals(LocatorUtils.property(thisLocator, "upperLimit", lhsUpperLimit), LocatorUtils.property(thatLocator, "upperLimit", rhsUpperLimit), lhsUpperLimit, rhsUpperLimit, (this.upperLimit!= null), (that.upperLimit!= null))) {
return false;
}
}
{
PositiveInt lhsDimensions;
lhsDimensions = this.getDimensions();
PositiveInt rhsDimensions;
rhsDimensions = that.getDimensions();
if (!strategy.equals(LocatorUtils.property(thisLocator, "dimensions", lhsDimensions), LocatorUtils.property(thatLocator, "dimensions", rhsDimensions), lhsDimensions, rhsDimensions, (this.dimensions!= null), (that.dimensions!= null))) {
return false;
}
}
{
SampledDataDataType lhsData;
lhsData = this.getData();
SampledDataDataType rhsData;
rhsData = that.getData();
if (!strategy.equals(LocatorUtils.property(thisLocator, "data", lhsData), LocatorUtils.property(thatLocator, "data", rhsData), lhsData, rhsData, (this.data!= null), (that.data!= 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);
{
SimpleQuantity theOrigin;
theOrigin = this.getOrigin();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "origin", theOrigin), currentHashCode, theOrigin, (this.origin!= null));
}
{
Decimal thePeriod;
thePeriod = this.getPeriod();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "period", thePeriod), currentHashCode, thePeriod, (this.period!= null));
}
{
Decimal theFactor;
theFactor = this.getFactor();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "factor", theFactor), currentHashCode, theFactor, (this.factor!= null));
}
{
Decimal theLowerLimit;
theLowerLimit = this.getLowerLimit();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "lowerLimit", theLowerLimit), currentHashCode, theLowerLimit, (this.lowerLimit!= null));
}
{
Decimal theUpperLimit;
theUpperLimit = this.getUpperLimit();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "upperLimit", theUpperLimit), currentHashCode, theUpperLimit, (this.upperLimit!= null));
}
{
PositiveInt theDimensions;
theDimensions = this.getDimensions();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "dimensions", theDimensions), currentHashCode, theDimensions, (this.dimensions!= null));
}
{
SampledDataDataType theData;
theData = this.getData();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "data", theData), currentHashCode, theData, (this.data!= 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);
{
SimpleQuantity theOrigin;
theOrigin = this.getOrigin();
strategy.appendField(locator, this, "origin", buffer, theOrigin, (this.origin!= null));
}
{
Decimal thePeriod;
thePeriod = this.getPeriod();
strategy.appendField(locator, this, "period", buffer, thePeriod, (this.period!= null));
}
{
Decimal theFactor;
theFactor = this.getFactor();
strategy.appendField(locator, this, "factor", buffer, theFactor, (this.factor!= null));
}
{
Decimal theLowerLimit;
theLowerLimit = this.getLowerLimit();
strategy.appendField(locator, this, "lowerLimit", buffer, theLowerLimit, (this.lowerLimit!= null));
}
{
Decimal theUpperLimit;
theUpperLimit = this.getUpperLimit();
strategy.appendField(locator, this, "upperLimit", buffer, theUpperLimit, (this.upperLimit!= null));
}
{
PositiveInt theDimensions;
theDimensions = this.getDimensions();
strategy.appendField(locator, this, "dimensions", buffer, theDimensions, (this.dimensions!= null));
}
{
SampledDataDataType theData;
theData = this.getData();
strategy.appendField(locator, this, "data", buffer, theData, (this.data!= null));
}
return buffer;
}
}