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

org.jvnet.hyperjaxb3.ejb.schemas.customizations.Basic Maven / Gradle / Ivy

There is a newer version: 4.0.8
Show newest version
//
// This file was generated by the Eclipse Implementation of JAXB, v4.0.5 
// See https://eclipse-ee4j.github.io/jaxb-ri 
// Any modifications to this file will be lost upon recompilation of the source schema. 
//


package org.jvnet.hyperjaxb3.ejb.schemas.customizations;

import jakarta.xml.bind.annotation.XmlAccessType;
import jakarta.xml.bind.annotation.XmlAccessorType;
import jakarta.xml.bind.annotation.XmlAttribute;
import jakarta.xml.bind.annotation.XmlElement;
import jakarta.xml.bind.annotation.XmlType;
import org.jvnet.jaxb.lang.CopyStrategy;
import org.jvnet.jaxb.lang.CopyTo;
import org.jvnet.jaxb.lang.Equals;
import org.jvnet.jaxb.lang.EqualsStrategy;
import org.jvnet.jaxb.lang.HashCode;
import org.jvnet.jaxb.lang.HashCodeStrategy;
import org.jvnet.jaxb.lang.JAXBCopyStrategy;
import org.jvnet.jaxb.lang.JAXBEqualsStrategy;
import org.jvnet.jaxb.lang.JAXBHashCodeStrategy;
import org.jvnet.jaxb.lang.JAXBMergeStrategy;
import org.jvnet.jaxb.lang.MergeFrom;
import org.jvnet.jaxb.lang.MergeStrategy;
import org.jvnet.jaxb.locator.ObjectLocator;
import org.jvnet.jaxb.locator.util.LocatorUtils;


/**
 * 

Java class for basic complex type

. * *

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

* *
{@code
 * 
 *   
 *     
 *       
 *         
 *       
 *       
 *     
 *   
 * 
 * }
* * */ @XmlAccessorType(XmlAccessType.FIELD) @XmlType(name = "basic", propOrder = { "enumeratedValue" }) public class Basic extends jakarta.xml.ns.persistence.orm.Basic implements Cloneable, Mergeable, CopyTo, Equals, HashCode, MergeFrom { @XmlElement(name = "enumerated-value") protected EnumeratedValue enumeratedValue; @XmlAttribute(name = "merge") protected Boolean merge; /** * Gets the value of the enumeratedValue property. * * @return * possible object is * {@link EnumeratedValue } * */ public EnumeratedValue getEnumeratedValue() { return enumeratedValue; } /** * Sets the value of the enumeratedValue property. * * @param value * allowed object is * {@link EnumeratedValue } * */ public void setEnumeratedValue(EnumeratedValue value) { this.enumeratedValue = value; } /** * Gets the value of the merge property. * * @return * possible object is * {@link Boolean } * */ public boolean isMerge() { if (merge == null) { return true; } else { return merge; } } /** * Sets the value of the merge property. * * @param value * allowed object is * {@link Boolean } * */ public void setMerge(Boolean value) { this.merge = value; } @Override public boolean equals(ObjectLocator thisLocator, ObjectLocator thatLocator, Object object, EqualsStrategy 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 Basic that = ((Basic) object); { EnumeratedValue lhsEnumeratedValue; lhsEnumeratedValue = this.getEnumeratedValue(); EnumeratedValue rhsEnumeratedValue; rhsEnumeratedValue = that.getEnumeratedValue(); if (!strategy.equals(LocatorUtils.property(thisLocator, "enumeratedValue", lhsEnumeratedValue), LocatorUtils.property(thatLocator, "enumeratedValue", rhsEnumeratedValue), lhsEnumeratedValue, rhsEnumeratedValue, (this.enumeratedValue!= null), (that.enumeratedValue!= null))) { return false; } } { boolean lhsMerge; lhsMerge = ((this.merge!= null)?this.isMerge():true); boolean rhsMerge; rhsMerge = ((that.merge!= null)?that.isMerge():true); if (!strategy.equals(LocatorUtils.property(thisLocator, "merge", lhsMerge), LocatorUtils.property(thatLocator, "merge", rhsMerge), lhsMerge, rhsMerge, (this.merge!= null), (that.merge!= null))) { return false; } } return true; } @Override public boolean equals(Object object) { final EqualsStrategy strategy = JAXBEqualsStrategy.getInstance(); return equals(null, null, object, strategy); } @Override public int hashCode(ObjectLocator locator, HashCodeStrategy strategy) { int currentHashCode = super.hashCode(locator, strategy); { EnumeratedValue theEnumeratedValue; theEnumeratedValue = this.getEnumeratedValue(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "enumeratedValue", theEnumeratedValue), currentHashCode, theEnumeratedValue, (this.enumeratedValue!= null)); } { boolean theMerge; theMerge = ((this.merge!= null)?this.isMerge():true); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "merge", theMerge), currentHashCode, theMerge, (this.merge!= null)); } return currentHashCode; } @Override public int hashCode() { final HashCodeStrategy strategy = JAXBHashCodeStrategy.getInstance(); return this.hashCode(null, strategy); } @Override public Object clone() { return copyTo(createNewInstance()); } @Override public Object copyTo(Object target) { final CopyStrategy strategy = JAXBCopyStrategy.getInstance(); return copyTo(null, target, strategy); } @Override public Object copyTo(ObjectLocator locator, Object target, CopyStrategy strategy) { final Object draftCopy = ((target == null)?createNewInstance():target); super.copyTo(locator, draftCopy, strategy); if (draftCopy instanceof Basic) { final Basic copy = ((Basic) draftCopy); { Boolean enumeratedValueShouldBeCopiedAndSet = strategy.shouldBeCopiedAndSet(locator, (this.enumeratedValue!= null)); if (enumeratedValueShouldBeCopiedAndSet == Boolean.TRUE) { EnumeratedValue sourceEnumeratedValue; sourceEnumeratedValue = this.getEnumeratedValue(); EnumeratedValue copyEnumeratedValue = ((EnumeratedValue) strategy.copy(LocatorUtils.property(locator, "enumeratedValue", sourceEnumeratedValue), sourceEnumeratedValue, (this.enumeratedValue!= null))); copy.setEnumeratedValue(copyEnumeratedValue); } else { if (enumeratedValueShouldBeCopiedAndSet == Boolean.FALSE) { copy.enumeratedValue = null; } } } { Boolean mergeShouldBeCopiedAndSet = strategy.shouldBeCopiedAndSet(locator, (this.merge!= null)); if (mergeShouldBeCopiedAndSet == Boolean.TRUE) { boolean sourceMerge; sourceMerge = ((this.merge!= null)?this.isMerge():true); boolean copyMerge = strategy.copy(LocatorUtils.property(locator, "merge", sourceMerge), sourceMerge, (this.merge!= null)); copy.setMerge(copyMerge); } else { if (mergeShouldBeCopiedAndSet == Boolean.FALSE) { copy.merge = null; } } } } return draftCopy; } @Override public Object createNewInstance() { return new Basic(); } @Override public void mergeFrom(Object left, Object right) { final MergeStrategy strategy = JAXBMergeStrategy.getInstance(); mergeFrom(null, null, left, right, strategy); } @Override public void mergeFrom(ObjectLocator leftLocator, ObjectLocator rightLocator, Object left, Object right, MergeStrategy strategy) { super.mergeFrom(leftLocator, rightLocator, left, right, strategy); if (right instanceof Basic) { final Basic target = this; final Basic leftObject = ((Basic) left); final Basic rightObject = ((Basic) right); { Boolean enumeratedValueShouldBeMergedAndSet = strategy.shouldBeMergedAndSet(leftLocator, rightLocator, (leftObject.enumeratedValue!= null), (rightObject.enumeratedValue!= null)); if (enumeratedValueShouldBeMergedAndSet == Boolean.TRUE) { EnumeratedValue lhsEnumeratedValue; lhsEnumeratedValue = leftObject.getEnumeratedValue(); EnumeratedValue rhsEnumeratedValue; rhsEnumeratedValue = rightObject.getEnumeratedValue(); EnumeratedValue mergedEnumeratedValue = ((EnumeratedValue) strategy.merge(LocatorUtils.property(leftLocator, "enumeratedValue", lhsEnumeratedValue), LocatorUtils.property(rightLocator, "enumeratedValue", rhsEnumeratedValue), lhsEnumeratedValue, rhsEnumeratedValue, (leftObject.enumeratedValue!= null), (rightObject.enumeratedValue!= null))); target.setEnumeratedValue(mergedEnumeratedValue); } else { if (enumeratedValueShouldBeMergedAndSet == Boolean.FALSE) { target.enumeratedValue = null; } } } { Boolean mergeShouldBeMergedAndSet = strategy.shouldBeMergedAndSet(leftLocator, rightLocator, (leftObject.merge!= null), (rightObject.merge!= null)); if (mergeShouldBeMergedAndSet == Boolean.TRUE) { boolean lhsMerge; lhsMerge = ((leftObject.merge!= null)?leftObject.isMerge():true); boolean rhsMerge; rhsMerge = ((rightObject.merge!= null)?rightObject.isMerge():true); boolean mergedMerge = ((boolean) strategy.merge(LocatorUtils.property(leftLocator, "merge", lhsMerge), LocatorUtils.property(rightLocator, "merge", rhsMerge), lhsMerge, rhsMerge, (leftObject.merge!= null), (rightObject.merge!= null))); target.setMerge(mergedMerge); } else { if (mergeShouldBeMergedAndSet == Boolean.FALSE) { target.merge = null; } } } } } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy