org.hl7.elm_modelinfo.r1.BindingInfo Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of model Show documentation
Show all versions of model Show documentation
The model 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 org.hl7.elm_modelinfo.r1;
import jakarta.xml.bind.annotation.XmlAccessType;
import jakarta.xml.bind.annotation.XmlAccessorType;
import jakarta.xml.bind.annotation.XmlAttribute;
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;
/**
* Specifies binding information for an element
*
* Java class for BindingInfo complex type.
*
*
The following schema fragment specifies the expected content contained within this class.
*
*
* <complexType name="BindingInfo">
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
* <attribute name="description" type="{http://www.w3.org/2001/XMLSchema}string" />
* <attribute name="strength" use="required" type="{urn:hl7-org:elm-modelinfo:r1}BindingStrength" />
* <attribute name="valueSet" use="required" type="{http://www.w3.org/2001/XMLSchema}anyURI" />
* </restriction>
* </complexContent>
* </complexType>
*
*
*
*/
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "BindingInfo", namespace = "urn:hl7-org:elm-modelinfo:r1")
public class BindingInfo implements Equals2, HashCode2, ToString2
{
@XmlAttribute(name = "name")
protected String name;
@XmlAttribute(name = "description")
protected String description;
@XmlAttribute(name = "strength", required = true)
protected BindingStrength strength;
@XmlAttribute(name = "valueSet", required = true)
@XmlSchemaType(name = "anyURI")
protected String valueSet;
/**
* Gets the value of the name property.
*
* @return
* possible object is
* {@link String }
*
*/
public String getName() {
return name;
}
/**
* Sets the value of the name property.
*
* @param value
* allowed object is
* {@link String }
*
*/
public void setName(String value) {
this.name = value;
}
/**
* Gets the value of the description property.
*
* @return
* possible object is
* {@link String }
*
*/
public String getDescription() {
return description;
}
/**
* Sets the value of the description property.
*
* @param value
* allowed object is
* {@link String }
*
*/
public void setDescription(String value) {
this.description = value;
}
/**
* Gets the value of the strength property.
*
* @return
* possible object is
* {@link BindingStrength }
*
*/
public BindingStrength getStrength() {
return strength;
}
/**
* Sets the value of the strength property.
*
* @param value
* allowed object is
* {@link BindingStrength }
*
*/
public void setStrength(BindingStrength value) {
this.strength = value;
}
/**
* Gets the value of the valueSet property.
*
* @return
* possible object is
* {@link String }
*
*/
public String getValueSet() {
return valueSet;
}
/**
* Sets the value of the valueSet property.
*
* @param value
* allowed object is
* {@link String }
*
*/
public void setValueSet(String value) {
this.valueSet = value;
}
public BindingInfo withName(String value) {
setName(value);
return this;
}
public BindingInfo withDescription(String value) {
setDescription(value);
return this;
}
public BindingInfo withStrength(BindingStrength value) {
setStrength(value);
return this;
}
public BindingInfo withValueSet(String value) {
setValueSet(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;
}
final BindingInfo that = ((BindingInfo) object);
{
String lhsName;
lhsName = this.getName();
String rhsName;
rhsName = that.getName();
if (!strategy.equals(LocatorUtils.property(thisLocator, "name", lhsName), LocatorUtils.property(thatLocator, "name", rhsName), lhsName, rhsName, (this.name!= null), (that.name!= null))) {
return false;
}
}
{
String lhsDescription;
lhsDescription = this.getDescription();
String rhsDescription;
rhsDescription = that.getDescription();
if (!strategy.equals(LocatorUtils.property(thisLocator, "description", lhsDescription), LocatorUtils.property(thatLocator, "description", rhsDescription), lhsDescription, rhsDescription, (this.description!= null), (that.description!= null))) {
return false;
}
}
{
BindingStrength lhsStrength;
lhsStrength = this.getStrength();
BindingStrength rhsStrength;
rhsStrength = that.getStrength();
if (!strategy.equals(LocatorUtils.property(thisLocator, "strength", lhsStrength), LocatorUtils.property(thatLocator, "strength", rhsStrength), lhsStrength, rhsStrength, (this.strength!= null), (that.strength!= null))) {
return false;
}
}
{
String lhsValueSet;
lhsValueSet = this.getValueSet();
String rhsValueSet;
rhsValueSet = that.getValueSet();
if (!strategy.equals(LocatorUtils.property(thisLocator, "valueSet", lhsValueSet), LocatorUtils.property(thatLocator, "valueSet", rhsValueSet), lhsValueSet, rhsValueSet, (this.valueSet!= null), (that.valueSet!= 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 = 1;
{
String theName;
theName = this.getName();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "name", theName), currentHashCode, theName, (this.name!= null));
}
{
String theDescription;
theDescription = this.getDescription();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "description", theDescription), currentHashCode, theDescription, (this.description!= null));
}
{
BindingStrength theStrength;
theStrength = this.getStrength();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "strength", theStrength), currentHashCode, theStrength, (this.strength!= null));
}
{
String theValueSet;
theValueSet = this.getValueSet();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "valueSet", theValueSet), currentHashCode, theValueSet, (this.valueSet!= 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) {
{
String theName;
theName = this.getName();
strategy.appendField(locator, this, "name", buffer, theName, (this.name!= null));
}
{
String theDescription;
theDescription = this.getDescription();
strategy.appendField(locator, this, "description", buffer, theDescription, (this.description!= null));
}
{
BindingStrength theStrength;
theStrength = this.getStrength();
strategy.appendField(locator, this, "strength", buffer, theStrength, (this.strength!= null));
}
{
String theValueSet;
theValueSet = this.getValueSet();
strategy.appendField(locator, this, "valueSet", buffer, theValueSet, (this.valueSet!= null));
}
return buffer;
}
}