Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
  //
  // 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: 2015.04.16 at 07:39:09 AM CEST 
  //
  
  
  package net.opengis.iso19139.gmd.v_20060504;
 
Information required enabling contact with the responsible person and/or organisation

Java class for CI_Contact_Type complex type.

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

 <complexType name="CI_Contact_Type">
   <complexContent>
     <extension base="{http://www.isotc211.org/2005/gco}AbstractObject_Type">
       <sequence>
         <element name="phone" type="{http://www.isotc211.org/2005/gmd}CI_Telephone_PropertyType" minOccurs="0"/>
         <element name="address" type="{http://www.isotc211.org/2005/gmd}CI_Address_PropertyType" minOccurs="0"/>
         <element name="onlineResource" type="{http://www.isotc211.org/2005/gmd}CI_OnlineResource_PropertyType" minOccurs="0"/>
         <element name="hoursOfService" type="{http://www.isotc211.org/2005/gco}CharacterString_PropertyType" minOccurs="0"/>
         <element name="contactInstructions" type="{http://www.isotc211.org/2005/gco}CharacterString_PropertyType" minOccurs="0"/>
       </sequence>
     </extension>
   </complexContent>
 </complexType>
 
 
 @XmlType(name = "CI_Contact_Type", propOrder = {
     "phone",
     "address",
     "onlineResource",
     "hoursOfService",
     "contactInstructions"
 })
 public class CIContactType
     extends AbstractObjectType
     implements CloneableCopyToEqualsHashCodeMergeFromToString
 {
 
     protected CITelephonePropertyType phone;
     protected CIAddressPropertyType address;
     protected CharacterStringPropertyType contactInstructions;

    
Gets the value of the phone property.

Returns:
possible object is
 
     public CITelephonePropertyType getPhone() {
         return ;
     }

    
Sets the value of the phone property.

Parameters:
value allowed object is
 
     public void setPhone(CITelephonePropertyType value) {
        this. = value;
    }

    
Gets the value of the address property.

Returns:
possible object is
    public CIAddressPropertyType getAddress() {
        return ;
    }

    
Sets the value of the address property.

Parameters:
value allowed object is
    public void setAddress(CIAddressPropertyType value) {
        this. = value;
    }

    
Gets the value of the onlineResource property.

Returns:
possible object is
        return ;
    }

    
Sets the value of the onlineResource property.

Parameters:
value allowed object is
    public void setOnlineResource(CIOnlineResourcePropertyType value) {
        this. = value;
    }

    
Gets the value of the hoursOfService property.

Returns:
possible object is
        return ;
    }

    
Sets the value of the hoursOfService property.

Parameters:
value allowed object is
    public void setHoursOfService(CharacterStringPropertyType value) {
        this. = value;
    }

    
Gets the value of the contactInstructions property.

Returns:
possible object is
        return ;
    }

    
Sets the value of the contactInstructions property.

Parameters:
value allowed object is
        this. = value;
    }
    public String toString() {
        final ToStringStrategy strategy = .;
        final StringBuilder buffer = new StringBuilder();
        append(nullbufferstrategy);
        return buffer.toString();
    }
    public StringBuilder append(ObjectLocator locatorStringBuilder bufferToStringStrategy strategy) {
        strategy.appendStart(locatorthisbuffer);
        appendFields(locatorbufferstrategy);
        strategy.appendEnd(locatorthisbuffer);
        return buffer;
    }
    public StringBuilder appendFields(ObjectLocator locatorStringBuilder bufferToStringStrategy strategy) {
        super.appendFields(locatorbufferstrategy);
        {
            CITelephonePropertyType thePhone;
            thePhone = this.getPhone();
            strategy.appendField(locatorthis"phone"bufferthePhone);
        }
        {
            CIAddressPropertyType theAddress;
            theAddress = this.getAddress();
            strategy.appendField(locatorthis"address"buffertheAddress);
        }
        {
            CIOnlineResourcePropertyType theOnlineResource;
            theOnlineResource = this.getOnlineResource();
            strategy.appendField(locatorthis"onlineResource"buffertheOnlineResource);
        }
        {
            CharacterStringPropertyType theHoursOfService;
            theHoursOfService = this.getHoursOfService();
            strategy.appendField(locatorthis"hoursOfService"buffertheHoursOfService);
        }
        {
            CharacterStringPropertyType theContactInstructions;
            theContactInstructions = this.getContactInstructions();
            strategy.appendField(locatorthis"contactInstructions"buffertheContactInstructions);
        }
        return buffer;
    }
    public boolean equals(ObjectLocator thisLocatorObjectLocator thatLocatorObject objectEqualsStrategy strategy) {
        if (!(object instanceof CIContactType)) {
            return false;
        }
        if (this == object) {
            return true;
        }
        if (!super.equals(thisLocatorthatLocatorobjectstrategy)) {
            return false;
        }
        final CIContactType that = ((CIContactTypeobject);
        {
            CITelephonePropertyType lhsPhone;
            lhsPhone = this.getPhone();
            CITelephonePropertyType rhsPhone;
            rhsPhone = that.getPhone();
            if (!strategy.equals(LocatorUtils.property(thisLocator"phone"lhsPhone), LocatorUtils.property(thatLocator"phone"rhsPhone), lhsPhonerhsPhone)) {
                return false;
            }
        }
        {
            CIAddressPropertyType lhsAddress;
            lhsAddress = this.getAddress();
            CIAddressPropertyType rhsAddress;
            rhsAddress = that.getAddress();
            if (!strategy.equals(LocatorUtils.property(thisLocator"address"lhsAddress), LocatorUtils.property(thatLocator"address"rhsAddress), lhsAddressrhsAddress)) {
                return false;
            }
        }
        {
            CIOnlineResourcePropertyType lhsOnlineResource;
            lhsOnlineResource = this.getOnlineResource();
            CIOnlineResourcePropertyType rhsOnlineResource;
            rhsOnlineResource = that.getOnlineResource();
            if (!strategy.equals(LocatorUtils.property(thisLocator"onlineResource"lhsOnlineResource), LocatorUtils.property(thatLocator"onlineResource"rhsOnlineResource), lhsOnlineResourcerhsOnlineResource)) {
                return false;
            }
        }
        {
            CharacterStringPropertyType lhsHoursOfService;
            lhsHoursOfService = this.getHoursOfService();
            CharacterStringPropertyType rhsHoursOfService;
            rhsHoursOfService = that.getHoursOfService();
            if (!strategy.equals(LocatorUtils.property(thisLocator"hoursOfService"lhsHoursOfService), LocatorUtils.property(thatLocator"hoursOfService"rhsHoursOfService), lhsHoursOfServicerhsHoursOfService)) {
                return false;
            }
        }
        {
            CharacterStringPropertyType lhsContactInstructions;
            lhsContactInstructions = this.getContactInstructions();
            CharacterStringPropertyType rhsContactInstructions;
            rhsContactInstructions = that.getContactInstructions();
            if (!strategy.equals(LocatorUtils.property(thisLocator"contactInstructions"lhsContactInstructions), LocatorUtils.property(thatLocator"contactInstructions"rhsContactInstructions), lhsContactInstructionsrhsContactInstructions)) {
                return false;
            }
        }
        return true;
    }
    public boolean equals(Object object) {
        final EqualsStrategy strategy = .;
        return equals(nullnullobjectstrategy);
    }
    public int hashCode(ObjectLocator locatorHashCodeStrategy strategy) {
        int currentHashCode = super.hashCode(locatorstrategy);
        {
            CITelephonePropertyType thePhone;
            thePhone = this.getPhone();
            currentHashCode = strategy.hashCode(LocatorUtils.property(locator"phone"thePhone), currentHashCodethePhone);
        }
        {
            CIAddressPropertyType theAddress;
            theAddress = this.getAddress();
            currentHashCode = strategy.hashCode(LocatorUtils.property(locator"address"theAddress), currentHashCodetheAddress);
        }
        {
            CIOnlineResourcePropertyType theOnlineResource;
            theOnlineResource = this.getOnlineResource();
            currentHashCode = strategy.hashCode(LocatorUtils.property(locator"onlineResource"theOnlineResource), currentHashCodetheOnlineResource);
        }
        {
            CharacterStringPropertyType theHoursOfService;
            theHoursOfService = this.getHoursOfService();
            currentHashCode = strategy.hashCode(LocatorUtils.property(locator"hoursOfService"theHoursOfService), currentHashCodetheHoursOfService);
        }
        {
            CharacterStringPropertyType theContactInstructions;
            theContactInstructions = this.getContactInstructions();
            currentHashCode = strategy.hashCode(LocatorUtils.property(locator"contactInstructions"theContactInstructions), currentHashCodetheContactInstructions);
        }
        return currentHashCode;
    }
    public int hashCode() {
        final HashCodeStrategy strategy = .;
        return this.hashCode(nullstrategy);
    }
    public Object clone() {
        return copyTo(createNewInstance());
    }
    public Object copyTo(Object target) {
        final CopyStrategy strategy = .;
        return copyTo(nulltargetstrategy);
    }
    public Object copyTo(ObjectLocator locatorObject targetCopyStrategy strategy) {
        final Object draftCopy = ((target == null)?createNewInstance():target);
        super.copyTo(locatordraftCopystrategy);
        if (draftCopy instanceof CIContactType) {
            final CIContactType copy = ((CIContactTypedraftCopy);
            if (this.!= null) {
                CITelephonePropertyType sourcePhone;
                sourcePhone = this.getPhone();
                CITelephonePropertyType copyPhone = ((CITelephonePropertyTypestrategy.copy(LocatorUtils.property(locator"phone"sourcePhone), sourcePhone));
                copy.setPhone(copyPhone);
            } else {
                copy.phone = null;
            }
            if (this.!= null) {
                CIAddressPropertyType sourceAddress;
                sourceAddress = this.getAddress();
                CIAddressPropertyType copyAddress = ((CIAddressPropertyTypestrategy.copy(LocatorUtils.property(locator"address"sourceAddress), sourceAddress));
                copy.setAddress(copyAddress);
            } else {
                copy.address = null;
            }
            if (this.!= null) {
                CIOnlineResourcePropertyType sourceOnlineResource;
                sourceOnlineResource = this.getOnlineResource();
                CIOnlineResourcePropertyType copyOnlineResource = ((CIOnlineResourcePropertyTypestrategy.copy(LocatorUtils.property(locator"onlineResource"sourceOnlineResource), sourceOnlineResource));
                copy.setOnlineResource(copyOnlineResource);
            } else {
                copy.onlineResource = null;
            }
            if (this.!= null) {
                CharacterStringPropertyType sourceHoursOfService;
                sourceHoursOfService = this.getHoursOfService();
                CharacterStringPropertyType copyHoursOfService = ((CharacterStringPropertyTypestrategy.copy(LocatorUtils.property(locator"hoursOfService"sourceHoursOfService), sourceHoursOfService));
                copy.setHoursOfService(copyHoursOfService);
            } else {
                copy.hoursOfService = null;
            }
            if (this.!= null) {
                CharacterStringPropertyType sourceContactInstructions;
                sourceContactInstructions = this.getContactInstructions();
                CharacterStringPropertyType copyContactInstructions = ((CharacterStringPropertyTypestrategy.copy(LocatorUtils.property(locator"contactInstructions"sourceContactInstructions), sourceContactInstructions));
                copy.setContactInstructions(copyContactInstructions);
            } else {
                copy.contactInstructions = null;
            }
        }
        return draftCopy;
    }
    public Object createNewInstance() {
        return new CIContactType();
    }
    public void mergeFrom(Object leftObject right) {
        final MergeStrategy strategy = .;
        mergeFrom(nullnullleftrightstrategy);
    }
    public void mergeFrom(ObjectLocator leftLocatorObjectLocator rightLocatorObject leftObject rightMergeStrategy strategy) {
        super.mergeFrom(leftLocatorrightLocatorleftrightstrategy);
        if (right instanceof CIContactType) {
            final CIContactType target = this;
            final CIContactType leftObject = ((CIContactTypeleft);
            final CIContactType rightObject = ((CIContactTyperight);
            {
                CITelephonePropertyType lhsPhone;
                lhsPhone = leftObject.getPhone();
                CITelephonePropertyType rhsPhone;
                rhsPhone = rightObject.getPhone();
                CITelephonePropertyType mergedPhone = ((CITelephonePropertyTypestrategy.merge(LocatorUtils.property(leftLocator"phone"lhsPhone), LocatorUtils.property(rightLocator"phone"rhsPhone), lhsPhonerhsPhone));
                target.setPhone(mergedPhone);
            }
            {
                CIAddressPropertyType lhsAddress;
                lhsAddress = leftObject.getAddress();
                CIAddressPropertyType rhsAddress;
                rhsAddress = rightObject.getAddress();
                CIAddressPropertyType mergedAddress = ((CIAddressPropertyTypestrategy.merge(LocatorUtils.property(leftLocator"address"lhsAddress), LocatorUtils.property(rightLocator"address"rhsAddress), lhsAddressrhsAddress));
                target.setAddress(mergedAddress);
            }
            {
                CIOnlineResourcePropertyType lhsOnlineResource;
                lhsOnlineResource = leftObject.getOnlineResource();
                CIOnlineResourcePropertyType rhsOnlineResource;
                rhsOnlineResource = rightObject.getOnlineResource();
                CIOnlineResourcePropertyType mergedOnlineResource = ((CIOnlineResourcePropertyTypestrategy.merge(LocatorUtils.property(leftLocator"onlineResource"lhsOnlineResource), LocatorUtils.property(rightLocator"onlineResource"rhsOnlineResource), lhsOnlineResourcerhsOnlineResource));
                target.setOnlineResource(mergedOnlineResource);
            }
            {
                CharacterStringPropertyType lhsHoursOfService;
                lhsHoursOfService = leftObject.getHoursOfService();
                CharacterStringPropertyType rhsHoursOfService;
                rhsHoursOfService = rightObject.getHoursOfService();
                CharacterStringPropertyType mergedHoursOfService = ((CharacterStringPropertyTypestrategy.merge(LocatorUtils.property(leftLocator"hoursOfService"lhsHoursOfService), LocatorUtils.property(rightLocator"hoursOfService"rhsHoursOfService), lhsHoursOfServicerhsHoursOfService));
                target.setHoursOfService(mergedHoursOfService);
            }
            {
                CharacterStringPropertyType lhsContactInstructions;
                lhsContactInstructions = leftObject.getContactInstructions();
                CharacterStringPropertyType rhsContactInstructions;
                rhsContactInstructions = rightObject.getContactInstructions();
                CharacterStringPropertyType mergedContactInstructions = ((CharacterStringPropertyTypestrategy.merge(LocatorUtils.property(leftLocator"contactInstructions"lhsContactInstructions), LocatorUtils.property(rightLocator"contactInstructions"rhsContactInstructions), lhsContactInstructionsrhsContactInstructions));
                target.setContactInstructions(mergedContactInstructions);
            }
        }
    }
        setPhone(value);
        return this;
    }
        setAddress(value);
        return this;
    }
        setOnlineResource(value);
        return this;
    }
        setHoursOfService(value);
        return this;
    }
        setContactInstructions(value);
        return this;
    }
    @Override
    public CIContactType withId(String value) {
        setId(value);
        return this;
    }
    @Override
    public CIContactType withUuid(String value) {
        setUuid(value);
        return this;
    }
New to GrepCode? Check out our FAQ X