All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.example.wsHT.api.xsd.impl.XMLGetCommentsResponseDocumentImpl Maven / Gradle / Ivy

The newest version!
/*
 * An XML document type.
 * Localname: getCommentsResponse
 * Namespace: http://www.example.org/WS-HT/api/xsd
 * Java type: org.example.wsHT.api.xsd.XMLGetCommentsResponseDocument
 *
 * Automatically generated - do not modify.
 */
package org.example.wsHT.api.xsd.impl;
/**
 * A document containing one getCommentsResponse(@http://www.example.org/WS-HT/api/xsd) element.
 *
 * This is a complex type.
 */
public class XMLGetCommentsResponseDocumentImpl extends org.apache.xmlbeans.impl.values.XmlComplexContentImpl implements org.example.wsHT.api.xsd.XMLGetCommentsResponseDocument
{
    private static final long serialVersionUID = 1L;
    
    public XMLGetCommentsResponseDocumentImpl(org.apache.xmlbeans.SchemaType sType)
    {
        super(sType);
    }
    
    private static final javax.xml.namespace.QName GETCOMMENTSRESPONSE$0 = 
        new javax.xml.namespace.QName("http://www.example.org/WS-HT/api/xsd", "getCommentsResponse");
    
    
    /**
     * Gets the "getCommentsResponse" element
     */
    public org.example.wsHT.api.xsd.XMLGetCommentsResponseDocument.GetCommentsResponse getGetCommentsResponse()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.example.wsHT.api.xsd.XMLGetCommentsResponseDocument.GetCommentsResponse target = null;
            target = (org.example.wsHT.api.xsd.XMLGetCommentsResponseDocument.GetCommentsResponse)get_store().find_element_user(GETCOMMENTSRESPONSE$0, 0);
            if (target == null)
            {
                return null;
            }
            return target;
        }
    }
    
    /**
     * Sets the "getCommentsResponse" element
     */
    public void setGetCommentsResponse(org.example.wsHT.api.xsd.XMLGetCommentsResponseDocument.GetCommentsResponse getCommentsResponse)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.example.wsHT.api.xsd.XMLGetCommentsResponseDocument.GetCommentsResponse target = null;
            target = (org.example.wsHT.api.xsd.XMLGetCommentsResponseDocument.GetCommentsResponse)get_store().find_element_user(GETCOMMENTSRESPONSE$0, 0);
            if (target == null)
            {
                target = (org.example.wsHT.api.xsd.XMLGetCommentsResponseDocument.GetCommentsResponse)get_store().add_element_user(GETCOMMENTSRESPONSE$0);
            }
            target.set(getCommentsResponse);
        }
    }
    
    /**
     * Appends and returns a new empty "getCommentsResponse" element
     */
    public org.example.wsHT.api.xsd.XMLGetCommentsResponseDocument.GetCommentsResponse addNewGetCommentsResponse()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.example.wsHT.api.xsd.XMLGetCommentsResponseDocument.GetCommentsResponse target = null;
            target = (org.example.wsHT.api.xsd.XMLGetCommentsResponseDocument.GetCommentsResponse)get_store().add_element_user(GETCOMMENTSRESPONSE$0);
            return target;
        }
    }
    /**
     * An XML getCommentsResponse(@http://www.example.org/WS-HT/api/xsd).
     *
     * This is a complex type.
     */
    public static class GetCommentsResponseImpl extends org.apache.xmlbeans.impl.values.XmlComplexContentImpl implements org.example.wsHT.api.xsd.XMLGetCommentsResponseDocument.GetCommentsResponse
    {
        private static final long serialVersionUID = 1L;
        
        public GetCommentsResponseImpl(org.apache.xmlbeans.SchemaType sType)
        {
            super(sType);
        }
        
        private static final javax.xml.namespace.QName COMMENT$0 = 
            new javax.xml.namespace.QName("http://www.example.org/WS-HT/api/xsd", "comment");
        
        
        /**
         * Gets a List of "comment" elements
         */
        public java.util.List getCommentList()
        {
            final class CommentList extends java.util.AbstractList
            {
                public org.example.wsHT.api.XMLTComment get(int i)
                    { return GetCommentsResponseImpl.this.getCommentArray(i); }
                
                public org.example.wsHT.api.XMLTComment set(int i, org.example.wsHT.api.XMLTComment o)
                {
                    org.example.wsHT.api.XMLTComment old = GetCommentsResponseImpl.this.getCommentArray(i);
                    GetCommentsResponseImpl.this.setCommentArray(i, o);
                    return old;
                }
                
                public void add(int i, org.example.wsHT.api.XMLTComment o)
                    { GetCommentsResponseImpl.this.insertNewComment(i).set(o); }
                
                public org.example.wsHT.api.XMLTComment remove(int i)
                {
                    org.example.wsHT.api.XMLTComment old = GetCommentsResponseImpl.this.getCommentArray(i);
                    GetCommentsResponseImpl.this.removeComment(i);
                    return old;
                }
                
                public int size()
                    { return GetCommentsResponseImpl.this.sizeOfCommentArray(); }
                
            }
            
            synchronized (monitor())
            {
                check_orphaned();
                return new CommentList();
            }
        }
        
        /**
         * Gets array of all "comment" elements
         * @deprecated
         */
        public org.example.wsHT.api.XMLTComment[] getCommentArray()
        {
            synchronized (monitor())
            {
                check_orphaned();
                java.util.List targetList = new java.util.ArrayList();
                get_store().find_all_element_users(COMMENT$0, targetList);
                org.example.wsHT.api.XMLTComment[] result = new org.example.wsHT.api.XMLTComment[targetList.size()];
                targetList.toArray(result);
                return result;
            }
        }
        
        /**
         * Gets ith "comment" element
         */
        public org.example.wsHT.api.XMLTComment getCommentArray(int i)
        {
            synchronized (monitor())
            {
                check_orphaned();
                org.example.wsHT.api.XMLTComment target = null;
                target = (org.example.wsHT.api.XMLTComment)get_store().find_element_user(COMMENT$0, i);
                if (target == null)
                {
                    throw new IndexOutOfBoundsException();
                }
                return target;
            }
        }
        
        /**
         * Returns number of "comment" element
         */
        public int sizeOfCommentArray()
        {
            synchronized (monitor())
            {
                check_orphaned();
                return get_store().count_elements(COMMENT$0);
            }
        }
        
        /**
         * Sets array of all "comment" element
         */
        public void setCommentArray(org.example.wsHT.api.XMLTComment[] commentArray)
        {
            synchronized (monitor())
            {
                check_orphaned();
                arraySetterHelper(commentArray, COMMENT$0);
            }
        }
        
        /**
         * Sets ith "comment" element
         */
        public void setCommentArray(int i, org.example.wsHT.api.XMLTComment comment)
        {
            synchronized (monitor())
            {
                check_orphaned();
                org.example.wsHT.api.XMLTComment target = null;
                target = (org.example.wsHT.api.XMLTComment)get_store().find_element_user(COMMENT$0, i);
                if (target == null)
                {
                    throw new IndexOutOfBoundsException();
                }
                target.set(comment);
            }
        }
        
        /**
         * Inserts and returns a new empty value (as xml) as the ith "comment" element
         */
        public org.example.wsHT.api.XMLTComment insertNewComment(int i)
        {
            synchronized (monitor())
            {
                check_orphaned();
                org.example.wsHT.api.XMLTComment target = null;
                target = (org.example.wsHT.api.XMLTComment)get_store().insert_element_user(COMMENT$0, i);
                return target;
            }
        }
        
        /**
         * Appends and returns a new empty value (as xml) as the last "comment" element
         */
        public org.example.wsHT.api.XMLTComment addNewComment()
        {
            synchronized (monitor())
            {
                check_orphaned();
                org.example.wsHT.api.XMLTComment target = null;
                target = (org.example.wsHT.api.XMLTComment)get_store().add_element_user(COMMENT$0);
                return target;
            }
        }
        
        /**
         * Removes the ith "comment" element
         */
        public void removeComment(int i)
        {
            synchronized (monitor())
            {
                check_orphaned();
                get_store().remove_element(COMMENT$0, i);
            }
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy