/*
 * An XML document type.
 * Localname: Insert
 * Namespace: http://docs.oasis-open.org/wsrf/2004/06/wsrf-WS-ResourceProperties-1.2-draft-01.xsd
 * Java type: org.activemq.ws.xmlbeans.resource.properties.InsertDocument
 *
 * Automatically generated - do not modify.
 */
package org.activemq.ws.xmlbeans.resource.properties.impl;
/**
 * A document containing one Insert(@http://docs.oasis-open.org/wsrf/2004/06/wsrf-WS-ResourceProperties-1.2-draft-01.xsd) element.
 *
 * This is a complex type.
 */
public class InsertDocumentImpl extends org.apache.xmlbeans.impl.values.XmlComplexContentImpl implements org.activemq.ws.xmlbeans.resource.properties.InsertDocument
{
    
    public InsertDocumentImpl(org.apache.xmlbeans.SchemaType sType)
    {
        super(sType);
    }
    
    private static final javax.xml.namespace.QName INSERT$0 = 
        new javax.xml.namespace.QName("http://docs.oasis-open.org/wsrf/2004/06/wsrf-WS-ResourceProperties-1.2-draft-01.xsd", "Insert");
    
    
    /**
     * Gets the "Insert" element
     */
    public org.activemq.ws.xmlbeans.resource.properties.InsertType getInsert()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.activemq.ws.xmlbeans.resource.properties.InsertType target = null;
            target = (org.activemq.ws.xmlbeans.resource.properties.InsertType)get_store().find_element_user(INSERT$0, 0);
            if (target == null)
            {
                return null;
            }
            return target;
        }
    }
    
    /**
     * Sets the "Insert" element
     */
    public void setInsert(org.activemq.ws.xmlbeans.resource.properties.InsertType insert)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.activemq.ws.xmlbeans.resource.properties.InsertType target = null;
            target = (org.activemq.ws.xmlbeans.resource.properties.InsertType)get_store().find_element_user(INSERT$0, 0);
            if (target == null)
            {
                target = (org.activemq.ws.xmlbeans.resource.properties.InsertType)get_store().add_element_user(INSERT$0);
            }
            target.set(insert);
        }
    }
    
    /**
     * Appends and returns a new empty "Insert" element
     */
    public org.activemq.ws.xmlbeans.resource.properties.InsertType addNewInsert()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.activemq.ws.xmlbeans.resource.properties.InsertType target = null;
            target = (org.activemq.ws.xmlbeans.resource.properties.InsertType)get_store().add_element_user(INSERT$0);
            return target;
        }
    }
}
