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