com.sun.java.xml.ns.persistence.Persistence Maven / Gradle / Ivy
//
// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.7
// See http://java.sun.com/xml/jaxb
// Any modifications to this file will be lost upon recompilation of the source schema.
// Generated on: 2014.09.16 at 02:12:07 AM CEST
//
package com.sun.java.xml.ns.persistence;
import java.util.ArrayList;
import java.util.List;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlAttribute;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlRootElement;
import javax.xml.bind.annotation.XmlType;
import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
import org.jvnet.jaxb2_commons.lang.CopyStrategy;
import org.jvnet.jaxb2_commons.lang.CopyTo;
import org.jvnet.jaxb2_commons.lang.Equals;
import org.jvnet.jaxb2_commons.lang.EqualsStrategy;
import org.jvnet.jaxb2_commons.lang.HashCode;
import org.jvnet.jaxb2_commons.lang.HashCodeStrategy;
import org.jvnet.jaxb2_commons.lang.JAXBCopyStrategy;
import org.jvnet.jaxb2_commons.lang.JAXBEqualsStrategy;
import org.jvnet.jaxb2_commons.lang.JAXBHashCodeStrategy;
import org.jvnet.jaxb2_commons.lang.JAXBMergeStrategy;
import org.jvnet.jaxb2_commons.lang.MergeFrom;
import org.jvnet.jaxb2_commons.lang.MergeStrategy;
import org.jvnet.jaxb2_commons.locator.ObjectLocator;
import org.jvnet.jaxb2_commons.locator.util.LocatorUtils;
/**
* Java class for anonymous complex type.
*
*
The following schema fragment specifies the expected content contained within this class.
*
*
* <complexType>
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <sequence>
* <element name="persistence-unit" maxOccurs="unbounded" minOccurs="0">
* <complexType>
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <sequence>
* <element name="description" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
* <element name="provider" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
* <element name="jta-data-source" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
* <element name="non-jta-data-source" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
* <element name="mapping-file" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded" minOccurs="0"/>
* <element name="jar-file" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded" minOccurs="0"/>
* <element name="class" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded" minOccurs="0"/>
* <element name="exclude-unlisted-classes" type="{http://www.w3.org/2001/XMLSchema}boolean" minOccurs="0"/>
* <element name="properties" minOccurs="0">
* <complexType>
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <sequence>
* <element name="property" maxOccurs="unbounded" minOccurs="0">
* <complexType>
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
* <attribute name="value" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
* </restriction>
* </complexContent>
* </complexType>
* </element>
* </sequence>
* </restriction>
* </complexContent>
* </complexType>
* </element>
* </sequence>
* <attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
* <attribute name="transaction-type" type="{http://java.sun.com/xml/ns/persistence}persistence-unit-transaction-type" />
* </restriction>
* </complexContent>
* </complexType>
* </element>
* </sequence>
* <attribute name="version" use="required" type="{http://java.sun.com/xml/ns/persistence}versionType" fixed="1.0" />
* </restriction>
* </complexContent>
* </complexType>
*
*
*
*/
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "", propOrder = {
"persistenceUnit"
})
@XmlRootElement(name = "persistence")
public class Persistence
implements Cloneable, CopyTo, Equals, HashCode, MergeFrom
{
@XmlElement(name = "persistence-unit")
protected List persistenceUnit;
@XmlAttribute(name = "version", required = true)
@XmlJavaTypeAdapter(CollapsedStringAdapter.class)
protected String version;
/**
* Gets the value of the persistenceUnit property.
*
*
* This accessor method returns a reference to the live list,
* not a snapshot. Therefore any modification you make to the
* returned list will be present inside the JAXB object.
* This is why there is not a set
method for the persistenceUnit property.
*
*
* For example, to add a new item, do as follows:
*
* getPersistenceUnit().add(newItem);
*
*
*
*
* Objects of the following type(s) are allowed in the list
* {@link Persistence.PersistenceUnit }
*
*
*/
public List getPersistenceUnit() {
if (persistenceUnit == null) {
persistenceUnit = new ArrayList();
}
return this.persistenceUnit;
}
/**
* Gets the value of the version property.
*
* @return
* possible object is
* {@link String }
*
*/
public String getVersion() {
if (version == null) {
return "1.0";
} else {
return version;
}
}
/**
* Sets the value of the version property.
*
* @param value
* allowed object is
* {@link String }
*
*/
public void setVersion(String value) {
this.version = value;
}
public boolean equals(ObjectLocator thisLocator, ObjectLocator thatLocator, Object object, EqualsStrategy strategy) {
if (!(object instanceof Persistence)) {
return false;
}
if (this == object) {
return true;
}
final Persistence that = ((Persistence) object);
{
List lhsPersistenceUnit;
lhsPersistenceUnit = (((this.persistenceUnit!= null)&&(!this.persistenceUnit.isEmpty()))?this.getPersistenceUnit():null);
List rhsPersistenceUnit;
rhsPersistenceUnit = (((that.persistenceUnit!= null)&&(!that.persistenceUnit.isEmpty()))?that.getPersistenceUnit():null);
if (!strategy.equals(LocatorUtils.property(thisLocator, "persistenceUnit", lhsPersistenceUnit), LocatorUtils.property(thatLocator, "persistenceUnit", rhsPersistenceUnit), lhsPersistenceUnit, rhsPersistenceUnit)) {
return false;
}
}
{
String lhsVersion;
lhsVersion = this.getVersion();
String rhsVersion;
rhsVersion = that.getVersion();
if (!strategy.equals(LocatorUtils.property(thisLocator, "version", lhsVersion), LocatorUtils.property(thatLocator, "version", rhsVersion), lhsVersion, rhsVersion)) {
return false;
}
}
return true;
}
public boolean equals(Object object) {
final EqualsStrategy strategy = JAXBEqualsStrategy.INSTANCE;
return equals(null, null, object, strategy);
}
public int hashCode(ObjectLocator locator, HashCodeStrategy strategy) {
int currentHashCode = 1;
{
List thePersistenceUnit;
thePersistenceUnit = (((this.persistenceUnit!= null)&&(!this.persistenceUnit.isEmpty()))?this.getPersistenceUnit():null);
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "persistenceUnit", thePersistenceUnit), currentHashCode, thePersistenceUnit);
}
{
String theVersion;
theVersion = this.getVersion();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "version", theVersion), currentHashCode, theVersion);
}
return currentHashCode;
}
public int hashCode() {
final HashCodeStrategy strategy = JAXBHashCodeStrategy.INSTANCE;
return this.hashCode(null, strategy);
}
public Object clone() {
return copyTo(createNewInstance());
}
public Object copyTo(Object target) {
final CopyStrategy strategy = JAXBCopyStrategy.INSTANCE;
return copyTo(null, target, strategy);
}
public Object copyTo(ObjectLocator locator, Object target, CopyStrategy strategy) {
final Object draftCopy = ((target == null)?createNewInstance():target);
if (draftCopy instanceof Persistence) {
final Persistence copy = ((Persistence) draftCopy);
if ((this.persistenceUnit!= null)&&(!this.persistenceUnit.isEmpty())) {
List sourcePersistenceUnit;
sourcePersistenceUnit = (((this.persistenceUnit!= null)&&(!this.persistenceUnit.isEmpty()))?this.getPersistenceUnit():null);
@SuppressWarnings("unchecked")
List copyPersistenceUnit = ((List ) strategy.copy(LocatorUtils.property(locator, "persistenceUnit", sourcePersistenceUnit), sourcePersistenceUnit));
copy.persistenceUnit = null;
if (copyPersistenceUnit!= null) {
List uniquePersistenceUnitl = copy.getPersistenceUnit();
uniquePersistenceUnitl.addAll(copyPersistenceUnit);
}
} else {
copy.persistenceUnit = null;
}
if (this.version!= null) {
String sourceVersion;
sourceVersion = this.getVersion();
String copyVersion = ((String) strategy.copy(LocatorUtils.property(locator, "version", sourceVersion), sourceVersion));
copy.setVersion(copyVersion);
} else {
copy.version = null;
}
}
return draftCopy;
}
public Object createNewInstance() {
return new Persistence();
}
public void mergeFrom(Object left, Object right) {
final MergeStrategy strategy = JAXBMergeStrategy.INSTANCE;
mergeFrom(null, null, left, right, strategy);
}
public void mergeFrom(ObjectLocator leftLocator, ObjectLocator rightLocator, Object left, Object right, MergeStrategy strategy) {
if (right instanceof Persistence) {
final Persistence target = this;
final Persistence leftObject = ((Persistence) left);
final Persistence rightObject = ((Persistence) right);
{
List lhsPersistenceUnit;
lhsPersistenceUnit = (((leftObject.persistenceUnit!= null)&&(!leftObject.persistenceUnit.isEmpty()))?leftObject.getPersistenceUnit():null);
List rhsPersistenceUnit;
rhsPersistenceUnit = (((rightObject.persistenceUnit!= null)&&(!rightObject.persistenceUnit.isEmpty()))?rightObject.getPersistenceUnit():null);
List mergedPersistenceUnit = ((List ) strategy.merge(LocatorUtils.property(leftLocator, "persistenceUnit", lhsPersistenceUnit), LocatorUtils.property(rightLocator, "persistenceUnit", rhsPersistenceUnit), lhsPersistenceUnit, rhsPersistenceUnit));
target.persistenceUnit = null;
if (mergedPersistenceUnit!= null) {
List uniquePersistenceUnitl = target.getPersistenceUnit();
uniquePersistenceUnitl.addAll(mergedPersistenceUnit);
}
}
{
String lhsVersion;
lhsVersion = leftObject.getVersion();
String rhsVersion;
rhsVersion = rightObject.getVersion();
String mergedVersion = ((String) strategy.merge(LocatorUtils.property(leftLocator, "version", lhsVersion), LocatorUtils.property(rightLocator, "version", rhsVersion), lhsVersion, rhsVersion));
target.setVersion(mergedVersion);
}
}
}
/**
*
*
* Configuration of a persistence unit.
*
*
*
* Java class for anonymous complex type.
*
*
The following schema fragment specifies the expected content contained within this class.
*
*
* <complexType>
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <sequence>
* <element name="description" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
* <element name="provider" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
* <element name="jta-data-source" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
* <element name="non-jta-data-source" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
* <element name="mapping-file" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded" minOccurs="0"/>
* <element name="jar-file" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded" minOccurs="0"/>
* <element name="class" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded" minOccurs="0"/>
* <element name="exclude-unlisted-classes" type="{http://www.w3.org/2001/XMLSchema}boolean" minOccurs="0"/>
* <element name="properties" minOccurs="0">
* <complexType>
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <sequence>
* <element name="property" maxOccurs="unbounded" minOccurs="0">
* <complexType>
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
* <attribute name="value" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
* </restriction>
* </complexContent>
* </complexType>
* </element>
* </sequence>
* </restriction>
* </complexContent>
* </complexType>
* </element>
* </sequence>
* <attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
* <attribute name="transaction-type" type="{http://java.sun.com/xml/ns/persistence}persistence-unit-transaction-type" />
* </restriction>
* </complexContent>
* </complexType>
*
*
*
*/
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "", propOrder = {
"description",
"provider",
"jtaDataSource",
"nonJtaDataSource",
"mappingFile",
"jarFile",
"clazz",
"excludeUnlistedClasses",
"properties"
})
public static class PersistenceUnit
implements Cloneable, CopyTo, Equals, HashCode, MergeFrom
{
protected String description;
protected String provider;
@XmlElement(name = "jta-data-source")
protected String jtaDataSource;
@XmlElement(name = "non-jta-data-source")
protected String nonJtaDataSource;
@XmlElement(name = "mapping-file")
protected List mappingFile;
@XmlElement(name = "jar-file")
protected List jarFile;
@XmlElement(name = "class")
protected List clazz;
@XmlElement(name = "exclude-unlisted-classes", defaultValue = "false")
protected Boolean excludeUnlistedClasses;
protected Persistence.PersistenceUnit.Properties properties;
@XmlAttribute(name = "name", required = true)
protected String name;
@XmlAttribute(name = "transaction-type")
@XmlJavaTypeAdapter(CollapsedStringAdapter.class)
protected String transactionType;
/**
* 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 provider property.
*
* @return
* possible object is
* {@link String }
*
*/
public String getProvider() {
return provider;
}
/**
* Sets the value of the provider property.
*
* @param value
* allowed object is
* {@link String }
*
*/
public void setProvider(String value) {
this.provider = value;
}
/**
* Gets the value of the jtaDataSource property.
*
* @return
* possible object is
* {@link String }
*
*/
public String getJtaDataSource() {
return jtaDataSource;
}
/**
* Sets the value of the jtaDataSource property.
*
* @param value
* allowed object is
* {@link String }
*
*/
public void setJtaDataSource(String value) {
this.jtaDataSource = value;
}
/**
* Gets the value of the nonJtaDataSource property.
*
* @return
* possible object is
* {@link String }
*
*/
public String getNonJtaDataSource() {
return nonJtaDataSource;
}
/**
* Sets the value of the nonJtaDataSource property.
*
* @param value
* allowed object is
* {@link String }
*
*/
public void setNonJtaDataSource(String value) {
this.nonJtaDataSource = value;
}
/**
* Gets the value of the mappingFile property.
*
*
* This accessor method returns a reference to the live list,
* not a snapshot. Therefore any modification you make to the
* returned list will be present inside the JAXB object.
* This is why there is not a set
method for the mappingFile property.
*
*
* For example, to add a new item, do as follows:
*
* getMappingFile().add(newItem);
*
*
*
*
* Objects of the following type(s) are allowed in the list
* {@link String }
*
*
*/
public List getMappingFile() {
if (mappingFile == null) {
mappingFile = new ArrayList();
}
return this.mappingFile;
}
/**
* Gets the value of the jarFile property.
*
*
* This accessor method returns a reference to the live list,
* not a snapshot. Therefore any modification you make to the
* returned list will be present inside the JAXB object.
* This is why there is not a set
method for the jarFile property.
*
*
* For example, to add a new item, do as follows:
*
* getJarFile().add(newItem);
*
*
*
*
* Objects of the following type(s) are allowed in the list
* {@link String }
*
*
*/
public List getJarFile() {
if (jarFile == null) {
jarFile = new ArrayList();
}
return this.jarFile;
}
/**
* Gets the value of the clazz property.
*
*
* This accessor method returns a reference to the live list,
* not a snapshot. Therefore any modification you make to the
* returned list will be present inside the JAXB object.
* This is why there is not a set
method for the clazz property.
*
*
* For example, to add a new item, do as follows:
*
* getClazz().add(newItem);
*
*
*
*
* Objects of the following type(s) are allowed in the list
* {@link String }
*
*
*/
public List getClazz() {
if (clazz == null) {
clazz = new ArrayList();
}
return this.clazz;
}
/**
* Gets the value of the excludeUnlistedClasses property.
*
* @return
* possible object is
* {@link Boolean }
*
*/
public Boolean isExcludeUnlistedClasses() {
return excludeUnlistedClasses;
}
/**
* Sets the value of the excludeUnlistedClasses property.
*
* @param value
* allowed object is
* {@link Boolean }
*
*/
public void setExcludeUnlistedClasses(Boolean value) {
this.excludeUnlistedClasses = value;
}
/**
* Gets the value of the properties property.
*
* @return
* possible object is
* {@link Persistence.PersistenceUnit.Properties }
*
*/
public Persistence.PersistenceUnit.Properties getProperties() {
return properties;
}
/**
* Sets the value of the properties property.
*
* @param value
* allowed object is
* {@link Persistence.PersistenceUnit.Properties }
*
*/
public void setProperties(Persistence.PersistenceUnit.Properties value) {
this.properties = value;
}
/**
* 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 transactionType property.
*
* @return
* possible object is
* {@link String }
*
*/
public String getTransactionType() {
return transactionType;
}
/**
* Sets the value of the transactionType property.
*
* @param value
* allowed object is
* {@link String }
*
*/
public void setTransactionType(String value) {
this.transactionType = value;
}
public boolean equals(ObjectLocator thisLocator, ObjectLocator thatLocator, Object object, EqualsStrategy strategy) {
if (!(object instanceof Persistence.PersistenceUnit)) {
return false;
}
if (this == object) {
return true;
}
final Persistence.PersistenceUnit that = ((Persistence.PersistenceUnit) object);
{
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)) {
return false;
}
}
{
String lhsProvider;
lhsProvider = this.getProvider();
String rhsProvider;
rhsProvider = that.getProvider();
if (!strategy.equals(LocatorUtils.property(thisLocator, "provider", lhsProvider), LocatorUtils.property(thatLocator, "provider", rhsProvider), lhsProvider, rhsProvider)) {
return false;
}
}
{
String lhsJtaDataSource;
lhsJtaDataSource = this.getJtaDataSource();
String rhsJtaDataSource;
rhsJtaDataSource = that.getJtaDataSource();
if (!strategy.equals(LocatorUtils.property(thisLocator, "jtaDataSource", lhsJtaDataSource), LocatorUtils.property(thatLocator, "jtaDataSource", rhsJtaDataSource), lhsJtaDataSource, rhsJtaDataSource)) {
return false;
}
}
{
String lhsNonJtaDataSource;
lhsNonJtaDataSource = this.getNonJtaDataSource();
String rhsNonJtaDataSource;
rhsNonJtaDataSource = that.getNonJtaDataSource();
if (!strategy.equals(LocatorUtils.property(thisLocator, "nonJtaDataSource", lhsNonJtaDataSource), LocatorUtils.property(thatLocator, "nonJtaDataSource", rhsNonJtaDataSource), lhsNonJtaDataSource, rhsNonJtaDataSource)) {
return false;
}
}
{
List lhsMappingFile;
lhsMappingFile = (((this.mappingFile!= null)&&(!this.mappingFile.isEmpty()))?this.getMappingFile():null);
List rhsMappingFile;
rhsMappingFile = (((that.mappingFile!= null)&&(!that.mappingFile.isEmpty()))?that.getMappingFile():null);
if (!strategy.equals(LocatorUtils.property(thisLocator, "mappingFile", lhsMappingFile), LocatorUtils.property(thatLocator, "mappingFile", rhsMappingFile), lhsMappingFile, rhsMappingFile)) {
return false;
}
}
{
List lhsJarFile;
lhsJarFile = (((this.jarFile!= null)&&(!this.jarFile.isEmpty()))?this.getJarFile():null);
List rhsJarFile;
rhsJarFile = (((that.jarFile!= null)&&(!that.jarFile.isEmpty()))?that.getJarFile():null);
if (!strategy.equals(LocatorUtils.property(thisLocator, "jarFile", lhsJarFile), LocatorUtils.property(thatLocator, "jarFile", rhsJarFile), lhsJarFile, rhsJarFile)) {
return false;
}
}
{
List lhsClazz;
lhsClazz = (((this.clazz!= null)&&(!this.clazz.isEmpty()))?this.getClazz():null);
List rhsClazz;
rhsClazz = (((that.clazz!= null)&&(!that.clazz.isEmpty()))?that.getClazz():null);
if (!strategy.equals(LocatorUtils.property(thisLocator, "clazz", lhsClazz), LocatorUtils.property(thatLocator, "clazz", rhsClazz), lhsClazz, rhsClazz)) {
return false;
}
}
{
Boolean lhsExcludeUnlistedClasses;
lhsExcludeUnlistedClasses = this.isExcludeUnlistedClasses();
Boolean rhsExcludeUnlistedClasses;
rhsExcludeUnlistedClasses = that.isExcludeUnlistedClasses();
if (!strategy.equals(LocatorUtils.property(thisLocator, "excludeUnlistedClasses", lhsExcludeUnlistedClasses), LocatorUtils.property(thatLocator, "excludeUnlistedClasses", rhsExcludeUnlistedClasses), lhsExcludeUnlistedClasses, rhsExcludeUnlistedClasses)) {
return false;
}
}
{
Persistence.PersistenceUnit.Properties lhsProperties;
lhsProperties = this.getProperties();
Persistence.PersistenceUnit.Properties rhsProperties;
rhsProperties = that.getProperties();
if (!strategy.equals(LocatorUtils.property(thisLocator, "properties", lhsProperties), LocatorUtils.property(thatLocator, "properties", rhsProperties), lhsProperties, rhsProperties)) {
return false;
}
}
{
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)) {
return false;
}
}
{
String lhsTransactionType;
lhsTransactionType = this.getTransactionType();
String rhsTransactionType;
rhsTransactionType = that.getTransactionType();
if (!strategy.equals(LocatorUtils.property(thisLocator, "transactionType", lhsTransactionType), LocatorUtils.property(thatLocator, "transactionType", rhsTransactionType), lhsTransactionType, rhsTransactionType)) {
return false;
}
}
return true;
}
public boolean equals(Object object) {
final EqualsStrategy strategy = JAXBEqualsStrategy.INSTANCE;
return equals(null, null, object, strategy);
}
public int hashCode(ObjectLocator locator, HashCodeStrategy strategy) {
int currentHashCode = 1;
{
String theDescription;
theDescription = this.getDescription();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "description", theDescription), currentHashCode, theDescription);
}
{
String theProvider;
theProvider = this.getProvider();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "provider", theProvider), currentHashCode, theProvider);
}
{
String theJtaDataSource;
theJtaDataSource = this.getJtaDataSource();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "jtaDataSource", theJtaDataSource), currentHashCode, theJtaDataSource);
}
{
String theNonJtaDataSource;
theNonJtaDataSource = this.getNonJtaDataSource();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "nonJtaDataSource", theNonJtaDataSource), currentHashCode, theNonJtaDataSource);
}
{
List theMappingFile;
theMappingFile = (((this.mappingFile!= null)&&(!this.mappingFile.isEmpty()))?this.getMappingFile():null);
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "mappingFile", theMappingFile), currentHashCode, theMappingFile);
}
{
List theJarFile;
theJarFile = (((this.jarFile!= null)&&(!this.jarFile.isEmpty()))?this.getJarFile():null);
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "jarFile", theJarFile), currentHashCode, theJarFile);
}
{
List theClazz;
theClazz = (((this.clazz!= null)&&(!this.clazz.isEmpty()))?this.getClazz():null);
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "clazz", theClazz), currentHashCode, theClazz);
}
{
Boolean theExcludeUnlistedClasses;
theExcludeUnlistedClasses = this.isExcludeUnlistedClasses();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "excludeUnlistedClasses", theExcludeUnlistedClasses), currentHashCode, theExcludeUnlistedClasses);
}
{
Persistence.PersistenceUnit.Properties theProperties;
theProperties = this.getProperties();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "properties", theProperties), currentHashCode, theProperties);
}
{
String theName;
theName = this.getName();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "name", theName), currentHashCode, theName);
}
{
String theTransactionType;
theTransactionType = this.getTransactionType();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "transactionType", theTransactionType), currentHashCode, theTransactionType);
}
return currentHashCode;
}
public int hashCode() {
final HashCodeStrategy strategy = JAXBHashCodeStrategy.INSTANCE;
return this.hashCode(null, strategy);
}
public Object clone() {
return copyTo(createNewInstance());
}
public Object copyTo(Object target) {
final CopyStrategy strategy = JAXBCopyStrategy.INSTANCE;
return copyTo(null, target, strategy);
}
public Object copyTo(ObjectLocator locator, Object target, CopyStrategy strategy) {
final Object draftCopy = ((target == null)?createNewInstance():target);
if (draftCopy instanceof Persistence.PersistenceUnit) {
final Persistence.PersistenceUnit copy = ((Persistence.PersistenceUnit) draftCopy);
if (this.description!= null) {
String sourceDescription;
sourceDescription = this.getDescription();
String copyDescription = ((String) strategy.copy(LocatorUtils.property(locator, "description", sourceDescription), sourceDescription));
copy.setDescription(copyDescription);
} else {
copy.description = null;
}
if (this.provider!= null) {
String sourceProvider;
sourceProvider = this.getProvider();
String copyProvider = ((String) strategy.copy(LocatorUtils.property(locator, "provider", sourceProvider), sourceProvider));
copy.setProvider(copyProvider);
} else {
copy.provider = null;
}
if (this.jtaDataSource!= null) {
String sourceJtaDataSource;
sourceJtaDataSource = this.getJtaDataSource();
String copyJtaDataSource = ((String) strategy.copy(LocatorUtils.property(locator, "jtaDataSource", sourceJtaDataSource), sourceJtaDataSource));
copy.setJtaDataSource(copyJtaDataSource);
} else {
copy.jtaDataSource = null;
}
if (this.nonJtaDataSource!= null) {
String sourceNonJtaDataSource;
sourceNonJtaDataSource = this.getNonJtaDataSource();
String copyNonJtaDataSource = ((String) strategy.copy(LocatorUtils.property(locator, "nonJtaDataSource", sourceNonJtaDataSource), sourceNonJtaDataSource));
copy.setNonJtaDataSource(copyNonJtaDataSource);
} else {
copy.nonJtaDataSource = null;
}
if ((this.mappingFile!= null)&&(!this.mappingFile.isEmpty())) {
List sourceMappingFile;
sourceMappingFile = (((this.mappingFile!= null)&&(!this.mappingFile.isEmpty()))?this.getMappingFile():null);
@SuppressWarnings("unchecked")
List copyMappingFile = ((List ) strategy.copy(LocatorUtils.property(locator, "mappingFile", sourceMappingFile), sourceMappingFile));
copy.mappingFile = null;
if (copyMappingFile!= null) {
List uniqueMappingFilel = copy.getMappingFile();
uniqueMappingFilel.addAll(copyMappingFile);
}
} else {
copy.mappingFile = null;
}
if ((this.jarFile!= null)&&(!this.jarFile.isEmpty())) {
List sourceJarFile;
sourceJarFile = (((this.jarFile!= null)&&(!this.jarFile.isEmpty()))?this.getJarFile():null);
@SuppressWarnings("unchecked")
List copyJarFile = ((List ) strategy.copy(LocatorUtils.property(locator, "jarFile", sourceJarFile), sourceJarFile));
copy.jarFile = null;
if (copyJarFile!= null) {
List uniqueJarFilel = copy.getJarFile();
uniqueJarFilel.addAll(copyJarFile);
}
} else {
copy.jarFile = null;
}
if ((this.clazz!= null)&&(!this.clazz.isEmpty())) {
List sourceClazz;
sourceClazz = (((this.clazz!= null)&&(!this.clazz.isEmpty()))?this.getClazz():null);
@SuppressWarnings("unchecked")
List copyClazz = ((List ) strategy.copy(LocatorUtils.property(locator, "clazz", sourceClazz), sourceClazz));
copy.clazz = null;
if (copyClazz!= null) {
List uniqueClazzl = copy.getClazz();
uniqueClazzl.addAll(copyClazz);
}
} else {
copy.clazz = null;
}
if (this.excludeUnlistedClasses!= null) {
Boolean sourceExcludeUnlistedClasses;
sourceExcludeUnlistedClasses = this.isExcludeUnlistedClasses();
Boolean copyExcludeUnlistedClasses = ((Boolean) strategy.copy(LocatorUtils.property(locator, "excludeUnlistedClasses", sourceExcludeUnlistedClasses), sourceExcludeUnlistedClasses));
copy.setExcludeUnlistedClasses(copyExcludeUnlistedClasses);
} else {
copy.excludeUnlistedClasses = null;
}
if (this.properties!= null) {
Persistence.PersistenceUnit.Properties sourceProperties;
sourceProperties = this.getProperties();
Persistence.PersistenceUnit.Properties copyProperties = ((Persistence.PersistenceUnit.Properties) strategy.copy(LocatorUtils.property(locator, "properties", sourceProperties), sourceProperties));
copy.setProperties(copyProperties);
} else {
copy.properties = null;
}
if (this.name!= null) {
String sourceName;
sourceName = this.getName();
String copyName = ((String) strategy.copy(LocatorUtils.property(locator, "name", sourceName), sourceName));
copy.setName(copyName);
} else {
copy.name = null;
}
if (this.transactionType!= null) {
String sourceTransactionType;
sourceTransactionType = this.getTransactionType();
String copyTransactionType = ((String) strategy.copy(LocatorUtils.property(locator, "transactionType", sourceTransactionType), sourceTransactionType));
copy.setTransactionType(copyTransactionType);
} else {
copy.transactionType = null;
}
}
return draftCopy;
}
public Object createNewInstance() {
return new Persistence.PersistenceUnit();
}
public void mergeFrom(Object left, Object right) {
final MergeStrategy strategy = JAXBMergeStrategy.INSTANCE;
mergeFrom(null, null, left, right, strategy);
}
public void mergeFrom(ObjectLocator leftLocator, ObjectLocator rightLocator, Object left, Object right, MergeStrategy strategy) {
if (right instanceof Persistence.PersistenceUnit) {
final Persistence.PersistenceUnit target = this;
final Persistence.PersistenceUnit leftObject = ((Persistence.PersistenceUnit) left);
final Persistence.PersistenceUnit rightObject = ((Persistence.PersistenceUnit) right);
{
String lhsDescription;
lhsDescription = leftObject.getDescription();
String rhsDescription;
rhsDescription = rightObject.getDescription();
String mergedDescription = ((String) strategy.merge(LocatorUtils.property(leftLocator, "description", lhsDescription), LocatorUtils.property(rightLocator, "description", rhsDescription), lhsDescription, rhsDescription));
target.setDescription(mergedDescription);
}
{
String lhsProvider;
lhsProvider = leftObject.getProvider();
String rhsProvider;
rhsProvider = rightObject.getProvider();
String mergedProvider = ((String) strategy.merge(LocatorUtils.property(leftLocator, "provider", lhsProvider), LocatorUtils.property(rightLocator, "provider", rhsProvider), lhsProvider, rhsProvider));
target.setProvider(mergedProvider);
}
{
String lhsJtaDataSource;
lhsJtaDataSource = leftObject.getJtaDataSource();
String rhsJtaDataSource;
rhsJtaDataSource = rightObject.getJtaDataSource();
String mergedJtaDataSource = ((String) strategy.merge(LocatorUtils.property(leftLocator, "jtaDataSource", lhsJtaDataSource), LocatorUtils.property(rightLocator, "jtaDataSource", rhsJtaDataSource), lhsJtaDataSource, rhsJtaDataSource));
target.setJtaDataSource(mergedJtaDataSource);
}
{
String lhsNonJtaDataSource;
lhsNonJtaDataSource = leftObject.getNonJtaDataSource();
String rhsNonJtaDataSource;
rhsNonJtaDataSource = rightObject.getNonJtaDataSource();
String mergedNonJtaDataSource = ((String) strategy.merge(LocatorUtils.property(leftLocator, "nonJtaDataSource", lhsNonJtaDataSource), LocatorUtils.property(rightLocator, "nonJtaDataSource", rhsNonJtaDataSource), lhsNonJtaDataSource, rhsNonJtaDataSource));
target.setNonJtaDataSource(mergedNonJtaDataSource);
}
{
List lhsMappingFile;
lhsMappingFile = (((leftObject.mappingFile!= null)&&(!leftObject.mappingFile.isEmpty()))?leftObject.getMappingFile():null);
List rhsMappingFile;
rhsMappingFile = (((rightObject.mappingFile!= null)&&(!rightObject.mappingFile.isEmpty()))?rightObject.getMappingFile():null);
List mergedMappingFile = ((List ) strategy.merge(LocatorUtils.property(leftLocator, "mappingFile", lhsMappingFile), LocatorUtils.property(rightLocator, "mappingFile", rhsMappingFile), lhsMappingFile, rhsMappingFile));
target.mappingFile = null;
if (mergedMappingFile!= null) {
List uniqueMappingFilel = target.getMappingFile();
uniqueMappingFilel.addAll(mergedMappingFile);
}
}
{
List lhsJarFile;
lhsJarFile = (((leftObject.jarFile!= null)&&(!leftObject.jarFile.isEmpty()))?leftObject.getJarFile():null);
List rhsJarFile;
rhsJarFile = (((rightObject.jarFile!= null)&&(!rightObject.jarFile.isEmpty()))?rightObject.getJarFile():null);
List mergedJarFile = ((List ) strategy.merge(LocatorUtils.property(leftLocator, "jarFile", lhsJarFile), LocatorUtils.property(rightLocator, "jarFile", rhsJarFile), lhsJarFile, rhsJarFile));
target.jarFile = null;
if (mergedJarFile!= null) {
List uniqueJarFilel = target.getJarFile();
uniqueJarFilel.addAll(mergedJarFile);
}
}
{
List lhsClazz;
lhsClazz = (((leftObject.clazz!= null)&&(!leftObject.clazz.isEmpty()))?leftObject.getClazz():null);
List rhsClazz;
rhsClazz = (((rightObject.clazz!= null)&&(!rightObject.clazz.isEmpty()))?rightObject.getClazz():null);
List mergedClazz = ((List ) strategy.merge(LocatorUtils.property(leftLocator, "clazz", lhsClazz), LocatorUtils.property(rightLocator, "clazz", rhsClazz), lhsClazz, rhsClazz));
target.clazz = null;
if (mergedClazz!= null) {
List uniqueClazzl = target.getClazz();
uniqueClazzl.addAll(mergedClazz);
}
}
{
Boolean lhsExcludeUnlistedClasses;
lhsExcludeUnlistedClasses = leftObject.isExcludeUnlistedClasses();
Boolean rhsExcludeUnlistedClasses;
rhsExcludeUnlistedClasses = rightObject.isExcludeUnlistedClasses();
Boolean mergedExcludeUnlistedClasses = ((Boolean) strategy.merge(LocatorUtils.property(leftLocator, "excludeUnlistedClasses", lhsExcludeUnlistedClasses), LocatorUtils.property(rightLocator, "excludeUnlistedClasses", rhsExcludeUnlistedClasses), lhsExcludeUnlistedClasses, rhsExcludeUnlistedClasses));
target.setExcludeUnlistedClasses(mergedExcludeUnlistedClasses);
}
{
Persistence.PersistenceUnit.Properties lhsProperties;
lhsProperties = leftObject.getProperties();
Persistence.PersistenceUnit.Properties rhsProperties;
rhsProperties = rightObject.getProperties();
Persistence.PersistenceUnit.Properties mergedProperties = ((Persistence.PersistenceUnit.Properties) strategy.merge(LocatorUtils.property(leftLocator, "properties", lhsProperties), LocatorUtils.property(rightLocator, "properties", rhsProperties), lhsProperties, rhsProperties));
target.setProperties(mergedProperties);
}
{
String lhsName;
lhsName = leftObject.getName();
String rhsName;
rhsName = rightObject.getName();
String mergedName = ((String) strategy.merge(LocatorUtils.property(leftLocator, "name", lhsName), LocatorUtils.property(rightLocator, "name", rhsName), lhsName, rhsName));
target.setName(mergedName);
}
{
String lhsTransactionType;
lhsTransactionType = leftObject.getTransactionType();
String rhsTransactionType;
rhsTransactionType = rightObject.getTransactionType();
String mergedTransactionType = ((String) strategy.merge(LocatorUtils.property(leftLocator, "transactionType", lhsTransactionType), LocatorUtils.property(rightLocator, "transactionType", rhsTransactionType), lhsTransactionType, rhsTransactionType));
target.setTransactionType(mergedTransactionType);
}
}
}
/**
* Java class for anonymous complex type.
*
*
The following schema fragment specifies the expected content contained within this class.
*
*
* <complexType>
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <sequence>
* <element name="property" maxOccurs="unbounded" minOccurs="0">
* <complexType>
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
* <attribute name="value" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
* </restriction>
* </complexContent>
* </complexType>
* </element>
* </sequence>
* </restriction>
* </complexContent>
* </complexType>
*
*
*
*/
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "", propOrder = {
"property"
})
public static class Properties
implements Cloneable, CopyTo, Equals, HashCode, MergeFrom
{
protected List property;
/**
* Gets the value of the property property.
*
*
* This accessor method returns a reference to the live list,
* not a snapshot. Therefore any modification you make to the
* returned list will be present inside the JAXB object.
* This is why there is not a set
method for the property property.
*
*
* For example, to add a new item, do as follows:
*
* getProperty().add(newItem);
*
*
*
*
* Objects of the following type(s) are allowed in the list
* {@link Persistence.PersistenceUnit.Properties.Property }
*
*
*/
public List getProperty() {
if (property == null) {
property = new ArrayList();
}
return this.property;
}
public boolean equals(ObjectLocator thisLocator, ObjectLocator thatLocator, Object object, EqualsStrategy strategy) {
if (!(object instanceof Persistence.PersistenceUnit.Properties)) {
return false;
}
if (this == object) {
return true;
}
final Persistence.PersistenceUnit.Properties that = ((Persistence.PersistenceUnit.Properties) object);
{
List lhsProperty;
lhsProperty = (((this.property!= null)&&(!this.property.isEmpty()))?this.getProperty():null);
List rhsProperty;
rhsProperty = (((that.property!= null)&&(!that.property.isEmpty()))?that.getProperty():null);
if (!strategy.equals(LocatorUtils.property(thisLocator, "property", lhsProperty), LocatorUtils.property(thatLocator, "property", rhsProperty), lhsProperty, rhsProperty)) {
return false;
}
}
return true;
}
public boolean equals(Object object) {
final EqualsStrategy strategy = JAXBEqualsStrategy.INSTANCE;
return equals(null, null, object, strategy);
}
public int hashCode(ObjectLocator locator, HashCodeStrategy strategy) {
int currentHashCode = 1;
{
List theProperty;
theProperty = (((this.property!= null)&&(!this.property.isEmpty()))?this.getProperty():null);
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "property", theProperty), currentHashCode, theProperty);
}
return currentHashCode;
}
public int hashCode() {
final HashCodeStrategy strategy = JAXBHashCodeStrategy.INSTANCE;
return this.hashCode(null, strategy);
}
public Object clone() {
return copyTo(createNewInstance());
}
public Object copyTo(Object target) {
final CopyStrategy strategy = JAXBCopyStrategy.INSTANCE;
return copyTo(null, target, strategy);
}
public Object copyTo(ObjectLocator locator, Object target, CopyStrategy strategy) {
final Object draftCopy = ((target == null)?createNewInstance():target);
if (draftCopy instanceof Persistence.PersistenceUnit.Properties) {
final Persistence.PersistenceUnit.Properties copy = ((Persistence.PersistenceUnit.Properties) draftCopy);
if ((this.property!= null)&&(!this.property.isEmpty())) {
List sourceProperty;
sourceProperty = (((this.property!= null)&&(!this.property.isEmpty()))?this.getProperty():null);
@SuppressWarnings("unchecked")
List copyProperty = ((List ) strategy.copy(LocatorUtils.property(locator, "property", sourceProperty), sourceProperty));
copy.property = null;
if (copyProperty!= null) {
List uniquePropertyl = copy.getProperty();
uniquePropertyl.addAll(copyProperty);
}
} else {
copy.property = null;
}
}
return draftCopy;
}
public Object createNewInstance() {
return new Persistence.PersistenceUnit.Properties();
}
public void mergeFrom(Object left, Object right) {
final MergeStrategy strategy = JAXBMergeStrategy.INSTANCE;
mergeFrom(null, null, left, right, strategy);
}
public void mergeFrom(ObjectLocator leftLocator, ObjectLocator rightLocator, Object left, Object right, MergeStrategy strategy) {
if (right instanceof Persistence.PersistenceUnit.Properties) {
final Persistence.PersistenceUnit.Properties target = this;
final Persistence.PersistenceUnit.Properties leftObject = ((Persistence.PersistenceUnit.Properties) left);
final Persistence.PersistenceUnit.Properties rightObject = ((Persistence.PersistenceUnit.Properties) right);
{
List lhsProperty;
lhsProperty = (((leftObject.property!= null)&&(!leftObject.property.isEmpty()))?leftObject.getProperty():null);
List rhsProperty;
rhsProperty = (((rightObject.property!= null)&&(!rightObject.property.isEmpty()))?rightObject.getProperty():null);
List mergedProperty = ((List ) strategy.merge(LocatorUtils.property(leftLocator, "property", lhsProperty), LocatorUtils.property(rightLocator, "property", rhsProperty), lhsProperty, rhsProperty));
target.property = null;
if (mergedProperty!= null) {
List uniquePropertyl = target.getProperty();
uniquePropertyl.addAll(mergedProperty);
}
}
}
}
/**
* Java class for anonymous complex type.
*
*
The following schema fragment specifies the expected content contained within this class.
*
*
* <complexType>
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
* <attribute name="value" use="required" type="{http://www.w3.org/2001/XMLSchema}string" />
* </restriction>
* </complexContent>
* </complexType>
*
*
*
*/
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "")
public static class Property
implements Cloneable, CopyTo, Equals, HashCode, MergeFrom
{
@XmlAttribute(name = "name", required = true)
protected String name;
@XmlAttribute(name = "value", required = true)
protected String value;
/**
* 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 value property.
*
* @return
* possible object is
* {@link String }
*
*/
public String getValue() {
return value;
}
/**
* Sets the value of the value property.
*
* @param value
* allowed object is
* {@link String }
*
*/
public void setValue(String value) {
this.value = value;
}
public boolean equals(ObjectLocator thisLocator, ObjectLocator thatLocator, Object object, EqualsStrategy strategy) {
if (!(object instanceof Persistence.PersistenceUnit.Properties.Property)) {
return false;
}
if (this == object) {
return true;
}
final Persistence.PersistenceUnit.Properties.Property that = ((Persistence.PersistenceUnit.Properties.Property) 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)) {
return false;
}
}
{
String lhsValue;
lhsValue = this.getValue();
String rhsValue;
rhsValue = that.getValue();
if (!strategy.equals(LocatorUtils.property(thisLocator, "value", lhsValue), LocatorUtils.property(thatLocator, "value", rhsValue), lhsValue, rhsValue)) {
return false;
}
}
return true;
}
public boolean equals(Object object) {
final EqualsStrategy strategy = JAXBEqualsStrategy.INSTANCE;
return equals(null, null, object, strategy);
}
public int hashCode(ObjectLocator locator, HashCodeStrategy strategy) {
int currentHashCode = 1;
{
String theName;
theName = this.getName();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "name", theName), currentHashCode, theName);
}
{
String theValue;
theValue = this.getValue();
currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "value", theValue), currentHashCode, theValue);
}
return currentHashCode;
}
public int hashCode() {
final HashCodeStrategy strategy = JAXBHashCodeStrategy.INSTANCE;
return this.hashCode(null, strategy);
}
public Object clone() {
return copyTo(createNewInstance());
}
public Object copyTo(Object target) {
final CopyStrategy strategy = JAXBCopyStrategy.INSTANCE;
return copyTo(null, target, strategy);
}
public Object copyTo(ObjectLocator locator, Object target, CopyStrategy strategy) {
final Object draftCopy = ((target == null)?createNewInstance():target);
if (draftCopy instanceof Persistence.PersistenceUnit.Properties.Property) {
final Persistence.PersistenceUnit.Properties.Property copy = ((Persistence.PersistenceUnit.Properties.Property) draftCopy);
if (this.name!= null) {
String sourceName;
sourceName = this.getName();
String copyName = ((String) strategy.copy(LocatorUtils.property(locator, "name", sourceName), sourceName));
copy.setName(copyName);
} else {
copy.name = null;
}
if (this.value!= null) {
String sourceValue;
sourceValue = this.getValue();
String copyValue = ((String) strategy.copy(LocatorUtils.property(locator, "value", sourceValue), sourceValue));
copy.setValue(copyValue);
} else {
copy.value = null;
}
}
return draftCopy;
}
public Object createNewInstance() {
return new Persistence.PersistenceUnit.Properties.Property();
}
public void mergeFrom(Object left, Object right) {
final MergeStrategy strategy = JAXBMergeStrategy.INSTANCE;
mergeFrom(null, null, left, right, strategy);
}
public void mergeFrom(ObjectLocator leftLocator, ObjectLocator rightLocator, Object left, Object right, MergeStrategy strategy) {
if (right instanceof Persistence.PersistenceUnit.Properties.Property) {
final Persistence.PersistenceUnit.Properties.Property target = this;
final Persistence.PersistenceUnit.Properties.Property leftObject = ((Persistence.PersistenceUnit.Properties.Property) left);
final Persistence.PersistenceUnit.Properties.Property rightObject = ((Persistence.PersistenceUnit.Properties.Property) right);
{
String lhsName;
lhsName = leftObject.getName();
String rhsName;
rhsName = rightObject.getName();
String mergedName = ((String) strategy.merge(LocatorUtils.property(leftLocator, "name", lhsName), LocatorUtils.property(rightLocator, "name", rhsName), lhsName, rhsName));
target.setName(mergedName);
}
{
String lhsValue;
lhsValue = leftObject.getValue();
String rhsValue;
rhsValue = rightObject.getValue();
String mergedValue = ((String) strategy.merge(LocatorUtils.property(leftLocator, "value", lhsValue), LocatorUtils.property(rightLocator, "value", rhsValue), lhsValue, rhsValue));
target.setValue(mergedValue);
}
}
}
}
}
}
}