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

com.smartbear.readyapi.junit.impl.PropertiesImpl Maven / Gradle / Ivy

The newest version!
/*
 * XML Type:  properties
 * Namespace: http://smartbear.com/readyapi/junit
 * Java type: com.smartbear.readyapi.junit.Properties
 *
 * Automatically generated - do not modify.
 */
package com.smartbear.readyapi.junit.impl;
/**
 * An XML properties(@http://smartbear.com/readyapi/junit).
 *
 * This is a complex type.
 */
public class PropertiesImpl extends org.apache.xmlbeans.impl.values.XmlComplexContentImpl implements com.smartbear.readyapi.junit.Properties
{
    private static final long serialVersionUID = 1L;
    
    public PropertiesImpl(org.apache.xmlbeans.SchemaType sType)
    {
        super(sType);
    }
    
    private static final javax.xml.namespace.QName PROPERTY$0 = 
        new javax.xml.namespace.QName("http://smartbear.com/readyapi/junit", "property");
    
    
    /**
     * Gets a List of "property" elements
     */
    public java.util.List getPropertyList()
    {
        final class PropertyList extends java.util.AbstractList
        {
            public com.smartbear.readyapi.junit.Property get(int i)
                { return PropertiesImpl.this.getPropertyArray(i); }
            
            public com.smartbear.readyapi.junit.Property set(int i, com.smartbear.readyapi.junit.Property o)
            {
                com.smartbear.readyapi.junit.Property old = PropertiesImpl.this.getPropertyArray(i);
                PropertiesImpl.this.setPropertyArray(i, o);
                return old;
            }
            
            public void add(int i, com.smartbear.readyapi.junit.Property o)
                { PropertiesImpl.this.insertNewProperty(i).set(o); }
            
            public com.smartbear.readyapi.junit.Property remove(int i)
            {
                com.smartbear.readyapi.junit.Property old = PropertiesImpl.this.getPropertyArray(i);
                PropertiesImpl.this.removeProperty(i);
                return old;
            }
            
            public int size()
                { return PropertiesImpl.this.sizeOfPropertyArray(); }
            
        }
        
        synchronized (monitor())
        {
            check_orphaned();
            return new PropertyList();
        }
    }
    
    /**
     * Gets array of all "property" elements
     * @deprecated
     */
    public com.smartbear.readyapi.junit.Property[] getPropertyArray()
    {
        synchronized (monitor())
        {
            check_orphaned();
            java.util.List targetList = new java.util.ArrayList();
            get_store().find_all_element_users(PROPERTY$0, targetList);
            com.smartbear.readyapi.junit.Property[] result = new com.smartbear.readyapi.junit.Property[targetList.size()];
            targetList.toArray(result);
            return result;
        }
    }
    
    /**
     * Gets ith "property" element
     */
    public com.smartbear.readyapi.junit.Property getPropertyArray(int i)
    {
        synchronized (monitor())
        {
            check_orphaned();
            com.smartbear.readyapi.junit.Property target = null;
            target = (com.smartbear.readyapi.junit.Property)get_store().find_element_user(PROPERTY$0, i);
            if (target == null)
            {
                throw new IndexOutOfBoundsException();
            }
            return target;
        }
    }
    
    /**
     * Returns number of "property" element
     */
    public int sizeOfPropertyArray()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(PROPERTY$0);
        }
    }
    
    /**
     * Sets array of all "property" element
     */
    public void setPropertyArray(com.smartbear.readyapi.junit.Property[] propertyArray)
    {
        synchronized (monitor())
        {
            check_orphaned();
            arraySetterHelper(propertyArray, PROPERTY$0);
        }
    }
    
    /**
     * Sets ith "property" element
     */
    public void setPropertyArray(int i, com.smartbear.readyapi.junit.Property property)
    {
        synchronized (monitor())
        {
            check_orphaned();
            com.smartbear.readyapi.junit.Property target = null;
            target = (com.smartbear.readyapi.junit.Property)get_store().find_element_user(PROPERTY$0, i);
            if (target == null)
            {
                throw new IndexOutOfBoundsException();
            }
            target.set(property);
        }
    }
    
    /**
     * Inserts and returns a new empty value (as xml) as the ith "property" element
     */
    public com.smartbear.readyapi.junit.Property insertNewProperty(int i)
    {
        synchronized (monitor())
        {
            check_orphaned();
            com.smartbear.readyapi.junit.Property target = null;
            target = (com.smartbear.readyapi.junit.Property)get_store().insert_element_user(PROPERTY$0, i);
            return target;
        }
    }
    
    /**
     * Appends and returns a new empty value (as xml) as the last "property" element
     */
    public com.smartbear.readyapi.junit.Property addNewProperty()
    {
        synchronized (monitor())
        {
            check_orphaned();
            com.smartbear.readyapi.junit.Property target = null;
            target = (com.smartbear.readyapi.junit.Property)get_store().add_element_user(PROPERTY$0);
            return target;
        }
    }
    
    /**
     * Removes the ith "property" element
     */
    public void removeProperty(int i)
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(PROPERTY$0, i);
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy