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;

Java class for MD_MediumFormatCode_PropertyType complex type.

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

 <complexType name="MD_MediumFormatCode_PropertyType">
   <complexContent>
     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
       <sequence minOccurs="0">
         <element ref="{http://www.isotc211.org/2005/gmd}MD_MediumFormatCode"/>
       </sequence>
       <attribute ref="{http://www.isotc211.org/2005/gco}nilReason"/>
     </restriction>
   </complexContent>
 </complexType>
 
 
 @XmlType(name = "MD_MediumFormatCode_PropertyType", propOrder = {
     "mdMediumFormatCode"
 })
     implements CloneableCopyToEqualsHashCodeMergeFromToString
 {
 
     @XmlElement(name = "MD_MediumFormatCode")
     @XmlAttribute(name = "nilReason", namespace = "http://www.isotc211.org/2005/gco")
     protected List<StringnilReason;

    
Gets the value of the mdMediumFormatCode property.

Returns:
possible object is
 
         return ;
     }

    
Sets the value of the mdMediumFormatCode property.

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

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

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

    getNilReason().add(newItem);
 

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

    public List<StringgetNilReason() {
        if ( == null) {
             = new ArrayList<String>();
        }
        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) {
        {
            CodeListValueType theMDMediumFormatCode;
            theMDMediumFormatCode = this.getMDMediumFormatCode();
            strategy.appendField(locatorthis"mdMediumFormatCode"buffertheMDMediumFormatCode);
        }
        {
            List<StringtheNilReason;
            theNilReason = (((this.!= null)&&(!this..isEmpty()))?this.getNilReason():null);
            strategy.appendField(locatorthis"nilReason"buffertheNilReason);
        }
        return buffer;
    }
    public boolean equals(ObjectLocator thisLocatorObjectLocator thatLocatorObject objectEqualsStrategy strategy) {
        if (!(object instanceof MDMediumFormatCodePropertyType)) {
            return false;
        }
        if (this == object) {
            return true;
        }
        final MDMediumFormatCodePropertyType that = ((MDMediumFormatCodePropertyTypeobject);
        {
            CodeListValueType lhsMDMediumFormatCode;
            lhsMDMediumFormatCode = this.getMDMediumFormatCode();
            CodeListValueType rhsMDMediumFormatCode;
            rhsMDMediumFormatCode = that.getMDMediumFormatCode();
            if (!strategy.equals(LocatorUtils.property(thisLocator"mdMediumFormatCode"lhsMDMediumFormatCode), LocatorUtils.property(thatLocator"mdMediumFormatCode"rhsMDMediumFormatCode), lhsMDMediumFormatCoderhsMDMediumFormatCode)) {
                return false;
            }
        }
        {
            List<StringlhsNilReason;
            lhsNilReason = (((this.!= null)&&(!this..isEmpty()))?this.getNilReason():null);
            List<StringrhsNilReason;
            rhsNilReason = (((that.nilReason!= null)&&(!that.nilReason.isEmpty()))?that.getNilReason():null);
            if (!strategy.equals(LocatorUtils.property(thisLocator"nilReason"lhsNilReason), LocatorUtils.property(thatLocator"nilReason"rhsNilReason), lhsNilReasonrhsNilReason)) {
                return false;
            }
        }
        return true;
    }
    public boolean equals(Object object) {
        final EqualsStrategy strategy = .;
        return equals(nullnullobjectstrategy);
    }
    public int hashCode(ObjectLocator locatorHashCodeStrategy strategy) {
        int currentHashCode = 1;
        {
            CodeListValueType theMDMediumFormatCode;
            theMDMediumFormatCode = this.getMDMediumFormatCode();
            currentHashCode = strategy.hashCode(LocatorUtils.property(locator"mdMediumFormatCode"theMDMediumFormatCode), currentHashCodetheMDMediumFormatCode);
        }
        {
            List<StringtheNilReason;
            theNilReason = (((this.!= null)&&(!this..isEmpty()))?this.getNilReason():null);
            currentHashCode = strategy.hashCode(LocatorUtils.property(locator"nilReason"theNilReason), currentHashCodetheNilReason);
        }
        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);
        if (draftCopy instanceof MDMediumFormatCodePropertyType) {
            final MDMediumFormatCodePropertyType copy = ((MDMediumFormatCodePropertyTypedraftCopy);
            if (this.!= null) {
                CodeListValueType sourceMDMediumFormatCode;
                sourceMDMediumFormatCode = this.getMDMediumFormatCode();
                CodeListValueType copyMDMediumFormatCode = ((CodeListValueTypestrategy.copy(LocatorUtils.property(locator"mdMediumFormatCode"sourceMDMediumFormatCode), sourceMDMediumFormatCode));
                copy.setMDMediumFormatCode(copyMDMediumFormatCode);
            } else {
                copy.mdMediumFormatCode = null;
            }
            if ((this.!= null)&&(!this..isEmpty())) {
                List<StringsourceNilReason;
                sourceNilReason = (((this.!= null)&&(!this..isEmpty()))?this.getNilReason():null);
                @SuppressWarnings("unchecked")
                List<StringcopyNilReason = ((List<String> ) strategy.copy(LocatorUtils.property(locator"nilReason"sourceNilReason), sourceNilReason));
                copy.nilReason = null;
                if (copyNilReason!= null) {
                    List<StringuniqueNilReasonl = copy.getNilReason();
                    uniqueNilReasonl.addAll(copyNilReason);
                }
            } else {
                copy.nilReason = null;
            }
        }
        return draftCopy;
    }
    public Object createNewInstance() {
        return new MDMediumFormatCodePropertyType();
    }
    public void mergeFrom(Object leftObject right) {
        final MergeStrategy strategy = .;
        mergeFrom(nullnullleftrightstrategy);
    }
    public void mergeFrom(ObjectLocator leftLocatorObjectLocator rightLocatorObject leftObject rightMergeStrategy strategy) {
        if (right instanceof MDMediumFormatCodePropertyType) {
            final MDMediumFormatCodePropertyType target = this;
            final MDMediumFormatCodePropertyType leftObject = ((MDMediumFormatCodePropertyTypeleft);
            final MDMediumFormatCodePropertyType rightObject = ((MDMediumFormatCodePropertyTyperight);
            {
                CodeListValueType lhsMDMediumFormatCode;
                lhsMDMediumFormatCode = leftObject.getMDMediumFormatCode();
                CodeListValueType rhsMDMediumFormatCode;
                rhsMDMediumFormatCode = rightObject.getMDMediumFormatCode();
                CodeListValueType mergedMDMediumFormatCode = ((CodeListValueTypestrategy.merge(LocatorUtils.property(leftLocator"mdMediumFormatCode"lhsMDMediumFormatCode), LocatorUtils.property(rightLocator"mdMediumFormatCode"rhsMDMediumFormatCode), lhsMDMediumFormatCoderhsMDMediumFormatCode));
                target.setMDMediumFormatCode(mergedMDMediumFormatCode);
            }
            {
                List<StringlhsNilReason;
                lhsNilReason = (((leftObject.nilReason!= null)&&(!leftObject.nilReason.isEmpty()))?leftObject.getNilReason():null);
                List<StringrhsNilReason;
                rhsNilReason = (((rightObject.nilReason!= null)&&(!rightObject.nilReason.isEmpty()))?rightObject.getNilReason():null);
                List<StringmergedNilReason = ((List<String> ) strategy.merge(LocatorUtils.property(leftLocator"nilReason"lhsNilReason), LocatorUtils.property(rightLocator"nilReason"rhsNilReason), lhsNilReasonrhsNilReason));
                target.nilReason = null;
                if (mergedNilReason!= null) {
                    List<StringuniqueNilReasonl = target.getNilReason();
                    uniqueNilReasonl.addAll(mergedNilReason);
                }
            }
        }
    }
    public void setNilReason(List<Stringvalue) {
        this. = null;
        List<Stringdraftl = this.getNilReason();
        draftl.addAll(value);
    }
        setMDMediumFormatCode(value);
        return this;
    }
        if (values!= null) {
            for (String valuevalues) {
                getNilReason().add(value);
            }
        }
        return this;
    }
        if (values!= null) {
            getNilReason().addAll(values);
        }
        return this;
    }
        setNilReason(value);
        return this;
    }
New to GrepCode? Check out our FAQ X