// // This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.11 // See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> // Any modifications to this file will be lost upon recompilation of the source schema. // Generated on: 2016.07.27 at 04:06:37 PM EDT // package org.isotc211._2005.gmd; import java.io.Serializable; import javax.validation.Valid; import javax.validation.constraints.NotNull; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.XmlType; import org.isotc211._2005.gco.AbstractObjectType; import org.jvnet.jaxb2_commons.lang.CopyStrategy2; import org.jvnet.jaxb2_commons.lang.CopyTo2; 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.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.JAXBToStringStrategy; import org.jvnet.jaxb2_commons.lang.MergeFrom2; import org.jvnet.jaxb2_commons.lang.MergeStrategy2; 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; /** * Encapsulates the dataset aggregation information * * <p>Java class for MD_AggregateInformation_Type complex type. * * <p>The following schema fragment specifies the expected content contained within this class. * * <pre> * <complexType name="MD_AggregateInformation_Type"> * <complexContent> * <extension base="{http://www.isotc211.org/2005/gco}AbstractObject_Type"> * <sequence> * <element name="aggregateDataSetName" type="{http://www.isotc211.org/2005/gmd}CI_Citation_PropertyType" minOccurs="0"/> * <element name="aggregateDataSetIdentifier" type="{http://www.isotc211.org/2005/gmd}MD_Identifier_PropertyType" minOccurs="0"/> * <element name="associationType" type="{http://www.isotc211.org/2005/gmd}DS_AssociationTypeCode_PropertyType"/> * <element name="initiativeType" type="{http://www.isotc211.org/2005/gmd}DS_InitiativeTypeCode_PropertyType" minOccurs="0"/> * </sequence> * </extension> * </complexContent> * </complexType> * </pre> * * */ @XmlAccessorType(XmlAccessType.FIELD) @XmlType(name = "MD_AggregateInformation_Type", propOrder = { "aggregateDataSetName", "aggregateDataSetIdentifier", "associationType", "initiativeType" }) public class MDAggregateInformationType extends AbstractObjectType implements Serializable, Cloneable, CopyTo2, Equals2, HashCode2, MergeFrom2, ToString2 { private final static long serialVersionUID = 1L; @Valid protected CICitationPropertyType aggregateDataSetName; @Valid protected MDIdentifierPropertyType aggregateDataSetIdentifier; @XmlElement(required = true) @NotNull(message = "MDAggregateInformationType.associationType {javax.validation.constraints.NotNull.message}") @Valid protected DSAssociationTypeCodePropertyType associationType; @Valid protected DSInitiativeTypeCodePropertyType initiativeType; /** * Gets the value of the aggregateDataSetName property. * * @return * possible object is * {@link CICitationPropertyType } * */ public CICitationPropertyType getAggregateDataSetName() { return aggregateDataSetName; } /** * Sets the value of the aggregateDataSetName property. * * @param value * allowed object is * {@link CICitationPropertyType } * */ public void setAggregateDataSetName(CICitationPropertyType value) { this.aggregateDataSetName = value; } public boolean isSetAggregateDataSetName() { return (this.aggregateDataSetName!= null); } /** * Gets the value of the aggregateDataSetIdentifier property. * * @return * possible object is * {@link MDIdentifierPropertyType } * */ public MDIdentifierPropertyType getAggregateDataSetIdentifier() { return aggregateDataSetIdentifier; } /** * Sets the value of the aggregateDataSetIdentifier property. * * @param value * allowed object is * {@link MDIdentifierPropertyType } * */ public void setAggregateDataSetIdentifier(MDIdentifierPropertyType value) { this.aggregateDataSetIdentifier = value; } public boolean isSetAggregateDataSetIdentifier() { return (this.aggregateDataSetIdentifier!= null); } /** * Gets the value of the associationType property. * * @return * possible object is * {@link DSAssociationTypeCodePropertyType } * */ public DSAssociationTypeCodePropertyType getAssociationType() { return associationType; } /** * Sets the value of the associationType property. * * @param value * allowed object is * {@link DSAssociationTypeCodePropertyType } * */ public void setAssociationType(DSAssociationTypeCodePropertyType value) { this.associationType = value; } public boolean isSetAssociationType() { return (this.associationType!= null); } /** * Gets the value of the initiativeType property. * * @return * possible object is * {@link DSInitiativeTypeCodePropertyType } * */ public DSInitiativeTypeCodePropertyType getInitiativeType() { return initiativeType; } /** * Sets the value of the initiativeType property. * * @param value * allowed object is * {@link DSInitiativeTypeCodePropertyType } * */ public void setInitiativeType(DSInitiativeTypeCodePropertyType value) { this.initiativeType = value; } public boolean isSetInitiativeType() { return (this.initiativeType!= null); } public String toString() { final ToStringStrategy2 strategy = JAXBToStringStrategy.INSTANCE; final StringBuilder buffer = new StringBuilder(); append(null, buffer, strategy); return buffer.toString(); } 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; } public StringBuilder appendFields(ObjectLocator locator, StringBuilder buffer, ToStringStrategy2 strategy) { super.appendFields(locator, buffer, strategy); { CICitationPropertyType theAggregateDataSetName; theAggregateDataSetName = this.getAggregateDataSetName(); strategy.appendField(locator, this, "aggregateDataSetName", buffer, theAggregateDataSetName, this.isSetAggregateDataSetName()); } { MDIdentifierPropertyType theAggregateDataSetIdentifier; theAggregateDataSetIdentifier = this.getAggregateDataSetIdentifier(); strategy.appendField(locator, this, "aggregateDataSetIdentifier", buffer, theAggregateDataSetIdentifier, this.isSetAggregateDataSetIdentifier()); } { DSAssociationTypeCodePropertyType theAssociationType; theAssociationType = this.getAssociationType(); strategy.appendField(locator, this, "associationType", buffer, theAssociationType, this.isSetAssociationType()); } { DSInitiativeTypeCodePropertyType theInitiativeType; theInitiativeType = this.getInitiativeType(); strategy.appendField(locator, this, "initiativeType", buffer, theInitiativeType, this.isSetInitiativeType()); } return buffer; } 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 MDAggregateInformationType that = ((MDAggregateInformationType) object); { CICitationPropertyType lhsAggregateDataSetName; lhsAggregateDataSetName = this.getAggregateDataSetName(); CICitationPropertyType rhsAggregateDataSetName; rhsAggregateDataSetName = that.getAggregateDataSetName(); if (!strategy.equals(LocatorUtils.property(thisLocator, "aggregateDataSetName", lhsAggregateDataSetName), LocatorUtils.property(thatLocator, "aggregateDataSetName", rhsAggregateDataSetName), lhsAggregateDataSetName, rhsAggregateDataSetName, this.isSetAggregateDataSetName(), that.isSetAggregateDataSetName())) { return false; } } { MDIdentifierPropertyType lhsAggregateDataSetIdentifier; lhsAggregateDataSetIdentifier = this.getAggregateDataSetIdentifier(); MDIdentifierPropertyType rhsAggregateDataSetIdentifier; rhsAggregateDataSetIdentifier = that.getAggregateDataSetIdentifier(); if (!strategy.equals(LocatorUtils.property(thisLocator, "aggregateDataSetIdentifier", lhsAggregateDataSetIdentifier), LocatorUtils.property(thatLocator, "aggregateDataSetIdentifier", rhsAggregateDataSetIdentifier), lhsAggregateDataSetIdentifier, rhsAggregateDataSetIdentifier, this.isSetAggregateDataSetIdentifier(), that.isSetAggregateDataSetIdentifier())) { return false; } } { DSAssociationTypeCodePropertyType lhsAssociationType; lhsAssociationType = this.getAssociationType(); DSAssociationTypeCodePropertyType rhsAssociationType; rhsAssociationType = that.getAssociationType(); if (!strategy.equals(LocatorUtils.property(thisLocator, "associationType", lhsAssociationType), LocatorUtils.property(thatLocator, "associationType", rhsAssociationType), lhsAssociationType, rhsAssociationType, this.isSetAssociationType(), that.isSetAssociationType())) { return false; } } { DSInitiativeTypeCodePropertyType lhsInitiativeType; lhsInitiativeType = this.getInitiativeType(); DSInitiativeTypeCodePropertyType rhsInitiativeType; rhsInitiativeType = that.getInitiativeType(); if (!strategy.equals(LocatorUtils.property(thisLocator, "initiativeType", lhsInitiativeType), LocatorUtils.property(thatLocator, "initiativeType", rhsInitiativeType), lhsInitiativeType, rhsInitiativeType, this.isSetInitiativeType(), that.isSetInitiativeType())) { return false; } } return true; } public boolean equals(Object object) { final EqualsStrategy2 strategy = JAXBEqualsStrategy.INSTANCE; return equals(null, null, object, strategy); } public int hashCode(ObjectLocator locator, HashCodeStrategy2 strategy) { int currentHashCode = super.hashCode(locator, strategy); { CICitationPropertyType theAggregateDataSetName; theAggregateDataSetName = this.getAggregateDataSetName(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "aggregateDataSetName", theAggregateDataSetName), currentHashCode, theAggregateDataSetName, this.isSetAggregateDataSetName()); } { MDIdentifierPropertyType theAggregateDataSetIdentifier; theAggregateDataSetIdentifier = this.getAggregateDataSetIdentifier(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "aggregateDataSetIdentifier", theAggregateDataSetIdentifier), currentHashCode, theAggregateDataSetIdentifier, this.isSetAggregateDataSetIdentifier()); } { DSAssociationTypeCodePropertyType theAssociationType; theAssociationType = this.getAssociationType(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "associationType", theAssociationType), currentHashCode, theAssociationType, this.isSetAssociationType()); } { DSInitiativeTypeCodePropertyType theInitiativeType; theInitiativeType = this.getInitiativeType(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "initiativeType", theInitiativeType), currentHashCode, theInitiativeType, this.isSetInitiativeType()); } return currentHashCode; } public int hashCode() { final HashCodeStrategy2 strategy = JAXBHashCodeStrategy.INSTANCE; return this.hashCode(null, strategy); } public Object clone() { return copyTo(createNewInstance()); } public Object copyTo(Object target) { final CopyStrategy2 strategy = JAXBCopyStrategy.INSTANCE; return copyTo(null, target, strategy); } public Object copyTo(ObjectLocator locator, Object target, CopyStrategy2 strategy) { final Object draftCopy = ((target == null)?createNewInstance():target); super.copyTo(locator, draftCopy, strategy); if (draftCopy instanceof MDAggregateInformationType) { final MDAggregateInformationType copy = ((MDAggregateInformationType) draftCopy); { Boolean aggregateDataSetNameShouldBeCopiedAndSet = strategy.shouldBeCopiedAndSet(locator, this.isSetAggregateDataSetName()); if (aggregateDataSetNameShouldBeCopiedAndSet == Boolean.TRUE) { CICitationPropertyType sourceAggregateDataSetName; sourceAggregateDataSetName = this.getAggregateDataSetName(); CICitationPropertyType copyAggregateDataSetName = ((CICitationPropertyType) strategy.copy(LocatorUtils.property(locator, "aggregateDataSetName", sourceAggregateDataSetName), sourceAggregateDataSetName, this.isSetAggregateDataSetName())); copy.setAggregateDataSetName(copyAggregateDataSetName); } else { if (aggregateDataSetNameShouldBeCopiedAndSet == Boolean.FALSE) { copy.aggregateDataSetName = null; } } } { Boolean aggregateDataSetIdentifierShouldBeCopiedAndSet = strategy.shouldBeCopiedAndSet(locator, this.isSetAggregateDataSetIdentifier()); if (aggregateDataSetIdentifierShouldBeCopiedAndSet == Boolean.TRUE) { MDIdentifierPropertyType sourceAggregateDataSetIdentifier; sourceAggregateDataSetIdentifier = this.getAggregateDataSetIdentifier(); MDIdentifierPropertyType copyAggregateDataSetIdentifier = ((MDIdentifierPropertyType) strategy.copy(LocatorUtils.property(locator, "aggregateDataSetIdentifier", sourceAggregateDataSetIdentifier), sourceAggregateDataSetIdentifier, this.isSetAggregateDataSetIdentifier())); copy.setAggregateDataSetIdentifier(copyAggregateDataSetIdentifier); } else { if (aggregateDataSetIdentifierShouldBeCopiedAndSet == Boolean.FALSE) { copy.aggregateDataSetIdentifier = null; } } } { Boolean associationTypeShouldBeCopiedAndSet = strategy.shouldBeCopiedAndSet(locator, this.isSetAssociationType()); if (associationTypeShouldBeCopiedAndSet == Boolean.TRUE) { DSAssociationTypeCodePropertyType sourceAssociationType; sourceAssociationType = this.getAssociationType(); DSAssociationTypeCodePropertyType copyAssociationType = ((DSAssociationTypeCodePropertyType) strategy.copy(LocatorUtils.property(locator, "associationType", sourceAssociationType), sourceAssociationType, this.isSetAssociationType())); copy.setAssociationType(copyAssociationType); } else { if (associationTypeShouldBeCopiedAndSet == Boolean.FALSE) { copy.associationType = null; } } } { Boolean initiativeTypeShouldBeCopiedAndSet = strategy.shouldBeCopiedAndSet(locator, this.isSetInitiativeType()); if (initiativeTypeShouldBeCopiedAndSet == Boolean.TRUE) { DSInitiativeTypeCodePropertyType sourceInitiativeType; sourceInitiativeType = this.getInitiativeType(); DSInitiativeTypeCodePropertyType copyInitiativeType = ((DSInitiativeTypeCodePropertyType) strategy.copy(LocatorUtils.property(locator, "initiativeType", sourceInitiativeType), sourceInitiativeType, this.isSetInitiativeType())); copy.setInitiativeType(copyInitiativeType); } else { if (initiativeTypeShouldBeCopiedAndSet == Boolean.FALSE) { copy.initiativeType = null; } } } } return draftCopy; } public Object createNewInstance() { return new MDAggregateInformationType(); } public void mergeFrom(Object left, Object right) { final MergeStrategy2 strategy = JAXBMergeStrategy.INSTANCE; mergeFrom(null, null, left, right, strategy); } public void mergeFrom(ObjectLocator leftLocator, ObjectLocator rightLocator, Object left, Object right, MergeStrategy2 strategy) { super.mergeFrom(leftLocator, rightLocator, left, right, strategy); if (right instanceof MDAggregateInformationType) { final MDAggregateInformationType target = this; final MDAggregateInformationType leftObject = ((MDAggregateInformationType) left); final MDAggregateInformationType rightObject = ((MDAggregateInformationType) right); { Boolean aggregateDataSetNameShouldBeMergedAndSet = strategy.shouldBeMergedAndSet(leftLocator, rightLocator, leftObject.isSetAggregateDataSetName(), rightObject.isSetAggregateDataSetName()); if (aggregateDataSetNameShouldBeMergedAndSet == Boolean.TRUE) { CICitationPropertyType lhsAggregateDataSetName; lhsAggregateDataSetName = leftObject.getAggregateDataSetName(); CICitationPropertyType rhsAggregateDataSetName; rhsAggregateDataSetName = rightObject.getAggregateDataSetName(); CICitationPropertyType mergedAggregateDataSetName = ((CICitationPropertyType) strategy.merge(LocatorUtils.property(leftLocator, "aggregateDataSetName", lhsAggregateDataSetName), LocatorUtils.property(rightLocator, "aggregateDataSetName", rhsAggregateDataSetName), lhsAggregateDataSetName, rhsAggregateDataSetName, leftObject.isSetAggregateDataSetName(), rightObject.isSetAggregateDataSetName())); target.setAggregateDataSetName(mergedAggregateDataSetName); } else { if (aggregateDataSetNameShouldBeMergedAndSet == Boolean.FALSE) { target.aggregateDataSetName = null; } } } { Boolean aggregateDataSetIdentifierShouldBeMergedAndSet = strategy.shouldBeMergedAndSet(leftLocator, rightLocator, leftObject.isSetAggregateDataSetIdentifier(), rightObject.isSetAggregateDataSetIdentifier()); if (aggregateDataSetIdentifierShouldBeMergedAndSet == Boolean.TRUE) { MDIdentifierPropertyType lhsAggregateDataSetIdentifier; lhsAggregateDataSetIdentifier = leftObject.getAggregateDataSetIdentifier(); MDIdentifierPropertyType rhsAggregateDataSetIdentifier; rhsAggregateDataSetIdentifier = rightObject.getAggregateDataSetIdentifier(); MDIdentifierPropertyType mergedAggregateDataSetIdentifier = ((MDIdentifierPropertyType) strategy.merge(LocatorUtils.property(leftLocator, "aggregateDataSetIdentifier", lhsAggregateDataSetIdentifier), LocatorUtils.property(rightLocator, "aggregateDataSetIdentifier", rhsAggregateDataSetIdentifier), lhsAggregateDataSetIdentifier, rhsAggregateDataSetIdentifier, leftObject.isSetAggregateDataSetIdentifier(), rightObject.isSetAggregateDataSetIdentifier())); target.setAggregateDataSetIdentifier(mergedAggregateDataSetIdentifier); } else { if (aggregateDataSetIdentifierShouldBeMergedAndSet == Boolean.FALSE) { target.aggregateDataSetIdentifier = null; } } } { Boolean associationTypeShouldBeMergedAndSet = strategy.shouldBeMergedAndSet(leftLocator, rightLocator, leftObject.isSetAssociationType(), rightObject.isSetAssociationType()); if (associationTypeShouldBeMergedAndSet == Boolean.TRUE) { DSAssociationTypeCodePropertyType lhsAssociationType; lhsAssociationType = leftObject.getAssociationType(); DSAssociationTypeCodePropertyType rhsAssociationType; rhsAssociationType = rightObject.getAssociationType(); DSAssociationTypeCodePropertyType mergedAssociationType = ((DSAssociationTypeCodePropertyType) strategy.merge(LocatorUtils.property(leftLocator, "associationType", lhsAssociationType), LocatorUtils.property(rightLocator, "associationType", rhsAssociationType), lhsAssociationType, rhsAssociationType, leftObject.isSetAssociationType(), rightObject.isSetAssociationType())); target.setAssociationType(mergedAssociationType); } else { if (associationTypeShouldBeMergedAndSet == Boolean.FALSE) { target.associationType = null; } } } { Boolean initiativeTypeShouldBeMergedAndSet = strategy.shouldBeMergedAndSet(leftLocator, rightLocator, leftObject.isSetInitiativeType(), rightObject.isSetInitiativeType()); if (initiativeTypeShouldBeMergedAndSet == Boolean.TRUE) { DSInitiativeTypeCodePropertyType lhsInitiativeType; lhsInitiativeType = leftObject.getInitiativeType(); DSInitiativeTypeCodePropertyType rhsInitiativeType; rhsInitiativeType = rightObject.getInitiativeType(); DSInitiativeTypeCodePropertyType mergedInitiativeType = ((DSInitiativeTypeCodePropertyType) strategy.merge(LocatorUtils.property(leftLocator, "initiativeType", lhsInitiativeType), LocatorUtils.property(rightLocator, "initiativeType", rhsInitiativeType), lhsInitiativeType, rhsInitiativeType, leftObject.isSetInitiativeType(), rightObject.isSetInitiativeType())); target.setInitiativeType(mergedInitiativeType); } else { if (initiativeTypeShouldBeMergedAndSet == Boolean.FALSE) { target.initiativeType = null; } } } } } }