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;
 
 import java.util.List;
Telephone numbers for contacting the responsible individual or organisation

Java class for CI_Telephone_Type complex type.

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

 <complexType name="CI_Telephone_Type">
   <complexContent>
     <extension base="{http://www.isotc211.org/2005/gco}AbstractObject_Type">
       <sequence>
         <element name="voice" type="{http://www.isotc211.org/2005/gco}CharacterString_PropertyType" maxOccurs="unbounded" minOccurs="0"/>
         <element name="facsimile" type="{http://www.isotc211.org/2005/gco}CharacterString_PropertyType" maxOccurs="unbounded" minOccurs="0"/>
       </sequence>
     </extension>
   </complexContent>
 </complexType>
 
 
 @XmlType(name = "CI_Telephone_Type", propOrder = {
     "voice",
     "facsimile"
 })
 public class CITelephoneType
     extends AbstractObjectType
     implements CloneableCopyToEqualsHashCodeMergeFromToString
 {
 
     protected List<CharacterStringPropertyTypevoice;
     protected List<CharacterStringPropertyTypefacsimile;

    
Gets the value of the voice 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 voice property.

For example, to add a new item, do as follows:

    getVoice().add(newItem);
 

Objects of the following type(s) are allowed in the list

 
         if ( == null) {
              = new ArrayList<CharacterStringPropertyType>();
         }
         return this.;
    }

    
Gets the value of the facsimile 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 facsimile property.

For example, to add a new item, do as follows:

    getFacsimile().add(newItem);
 

Objects of the following type(s) are allowed in the list

        if ( == null) {
             = new ArrayList<CharacterStringPropertyType>();
        }
        return this.;
    }
    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);
        {
            List<CharacterStringPropertyTypetheVoice;
            theVoice = (((this.!= null)&&(!this..isEmpty()))?this.getVoice():null);
            strategy.appendField(locatorthis"voice"buffertheVoice);
        }
        {
            List<CharacterStringPropertyTypetheFacsimile;
            theFacsimile = (((this.!= null)&&(!this..isEmpty()))?this.getFacsimile():null);
            strategy.appendField(locatorthis"facsimile"buffertheFacsimile);
        }
        return buffer;
    }
    public boolean equals(ObjectLocator thisLocatorObjectLocator thatLocatorObject objectEqualsStrategy strategy) {
        if (!(object instanceof CITelephoneType)) {
            return false;
        }
        if (this == object) {
            return true;
        }
        if (!super.equals(thisLocatorthatLocatorobjectstrategy)) {
            return false;
        }
        final CITelephoneType that = ((CITelephoneTypeobject);
        {
            List<CharacterStringPropertyTypelhsVoice;
            lhsVoice = (((this.!= null)&&(!this..isEmpty()))?this.getVoice():null);
            List<CharacterStringPropertyTyperhsVoice;
            rhsVoice = (((that.voice!= null)&&(!that.voice.isEmpty()))?that.getVoice():null);
            if (!strategy.equals(LocatorUtils.property(thisLocator"voice"lhsVoice), LocatorUtils.property(thatLocator"voice"rhsVoice), lhsVoicerhsVoice)) {
                return false;
            }
        }
        {
            List<CharacterStringPropertyTypelhsFacsimile;
            lhsFacsimile = (((this.!= null)&&(!this..isEmpty()))?this.getFacsimile():null);
            List<CharacterStringPropertyTyperhsFacsimile;
            rhsFacsimile = (((that.facsimile!= null)&&(!that.facsimile.isEmpty()))?that.getFacsimile():null);
            if (!strategy.equals(LocatorUtils.property(thisLocator"facsimile"lhsFacsimile), LocatorUtils.property(thatLocator"facsimile"rhsFacsimile), lhsFacsimilerhsFacsimile)) {
                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);
        {
            List<CharacterStringPropertyTypetheVoice;
            theVoice = (((this.!= null)&&(!this..isEmpty()))?this.getVoice():null);
            currentHashCode = strategy.hashCode(LocatorUtils.property(locator"voice"theVoice), currentHashCodetheVoice);
        }
        {
            List<CharacterStringPropertyTypetheFacsimile;
            theFacsimile = (((this.!= null)&&(!this..isEmpty()))?this.getFacsimile():null);
            currentHashCode = strategy.hashCode(LocatorUtils.property(locator"facsimile"theFacsimile), currentHashCodetheFacsimile);
        }
        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 CITelephoneType) {
            final CITelephoneType copy = ((CITelephoneTypedraftCopy);
            if ((this.!= null)&&(!this..isEmpty())) {
                List<CharacterStringPropertyTypesourceVoice;
                sourceVoice = (((this.!= null)&&(!this..isEmpty()))?this.getVoice():null);
                @SuppressWarnings("unchecked")
                List<CharacterStringPropertyTypecopyVoice = ((List<CharacterStringPropertyType> ) strategy.copy(LocatorUtils.property(locator"voice"sourceVoice), sourceVoice));
                copy.voice = null;
                if (copyVoice!= null) {
                    List<CharacterStringPropertyTypeuniqueVoicel = copy.getVoice();
                    uniqueVoicel.addAll(copyVoice);
                }
            } else {
                copy.voice = null;
            }
            if ((this.!= null)&&(!this..isEmpty())) {
                List<CharacterStringPropertyTypesourceFacsimile;
                sourceFacsimile = (((this.!= null)&&(!this..isEmpty()))?this.getFacsimile():null);
                @SuppressWarnings("unchecked")
                List<CharacterStringPropertyTypecopyFacsimile = ((List<CharacterStringPropertyType> ) strategy.copy(LocatorUtils.property(locator"facsimile"sourceFacsimile), sourceFacsimile));
                copy.facsimile = null;
                if (copyFacsimile!= null) {
                    List<CharacterStringPropertyTypeuniqueFacsimilel = copy.getFacsimile();
                    uniqueFacsimilel.addAll(copyFacsimile);
                }
            } else {
                copy.facsimile = null;
            }
        }
        return draftCopy;
    }
    public Object createNewInstance() {
        return new CITelephoneType();
    }
    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 CITelephoneType) {
            final CITelephoneType target = this;
            final CITelephoneType leftObject = ((CITelephoneTypeleft);
            final CITelephoneType rightObject = ((CITelephoneTyperight);
            {
                List<CharacterStringPropertyTypelhsVoice;
                lhsVoice = (((leftObject.voice!= null)&&(!leftObject.voice.isEmpty()))?leftObject.getVoice():null);
                List<CharacterStringPropertyTyperhsVoice;
                rhsVoice = (((rightObject.voice!= null)&&(!rightObject.voice.isEmpty()))?rightObject.getVoice():null);
                List<CharacterStringPropertyTypemergedVoice = ((List<CharacterStringPropertyType> ) strategy.merge(LocatorUtils.property(leftLocator"voice"lhsVoice), LocatorUtils.property(rightLocator"voice"rhsVoice), lhsVoicerhsVoice));
                target.voice = null;
                if (mergedVoice!= null) {
                    List<CharacterStringPropertyTypeuniqueVoicel = target.getVoice();
                    uniqueVoicel.addAll(mergedVoice);
                }
            }
            {
                List<CharacterStringPropertyTypelhsFacsimile;
                lhsFacsimile = (((leftObject.facsimile!= null)&&(!leftObject.facsimile.isEmpty()))?leftObject.getFacsimile():null);
                List<CharacterStringPropertyTyperhsFacsimile;
                rhsFacsimile = (((rightObject.facsimile!= null)&&(!rightObject.facsimile.isEmpty()))?rightObject.getFacsimile():null);
                List<CharacterStringPropertyTypemergedFacsimile = ((List<CharacterStringPropertyType> ) strategy.merge(LocatorUtils.property(leftLocator"facsimile"lhsFacsimile), LocatorUtils.property(rightLocator"facsimile"rhsFacsimile), lhsFacsimilerhsFacsimile));
                target.facsimile = null;
                if (mergedFacsimile!= null) {
                    List<CharacterStringPropertyTypeuniqueFacsimilel = target.getFacsimile();
                    uniqueFacsimilel.addAll(mergedFacsimile);
                }
            }
        }
    }
    public void setVoice(List<CharacterStringPropertyTypevalue) {
        this. = null;
        List<CharacterStringPropertyTypedraftl = this.getVoice();
        draftl.addAll(value);
    }
    public void setFacsimile(List<CharacterStringPropertyTypevalue) {
        this. = null;
        List<CharacterStringPropertyTypedraftl = this.getFacsimile();
        draftl.addAll(value);
    }
        if (values!= null) {
            for (CharacterStringPropertyType valuevalues) {
                getVoice().add(value);
            }
        }
        return this;
    }
        if (values!= null) {
            getVoice().addAll(values);
        }
        return this;
    }
        if (values!= null) {
            for (CharacterStringPropertyType valuevalues) {
                getFacsimile().add(value);
            }
        }
        return this;
    }
        if (values!= null) {
            getFacsimile().addAll(values);
        }
        return this;
    }
        setVoice(value);
        return this;
    }
        setFacsimile(value);
        return this;
    }
    @Override
    public CITelephoneType withId(String value) {
        setId(value);
        return this;
    }
    @Override
    public CITelephoneType withUuid(String value) {
        setUuid(value);
        return this;
    }
New to GrepCode? Check out our FAQ X