/*
 * An XML document type.
 * Localname: Selector
 * Namespace: http://docs.oasis-open.org/wsn/2004/06/wsn-WS-BaseNotification-1.2-draft-01.xsd
 * Java type: org.activemq.ws.xmlbeans.notification.base.SelectorDocument
 *
 * Automatically generated - do not modify.
 */
package org.activemq.ws.xmlbeans.notification.base.impl;
/**
 * A document containing one Selector(@http://docs.oasis-open.org/wsn/2004/06/wsn-WS-BaseNotification-1.2-draft-01.xsd) element.
 *
 * This is a complex type.
 */
public class SelectorDocumentImpl extends org.apache.xmlbeans.impl.values.XmlComplexContentImpl implements org.activemq.ws.xmlbeans.notification.base.SelectorDocument
{
    
    public SelectorDocumentImpl(org.apache.xmlbeans.SchemaType sType)
    {
        super(sType);
    }
    
    private static final javax.xml.namespace.QName SELECTOR$0 = 
        new javax.xml.namespace.QName("http://docs.oasis-open.org/wsn/2004/06/wsn-WS-BaseNotification-1.2-draft-01.xsd", "Selector");
    
    
    /**
     * Gets the "Selector" element
     */
    public org.activemq.ws.xmlbeans.resource.properties.QueryExpressionType getSelector()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.activemq.ws.xmlbeans.resource.properties.QueryExpressionType target = null;
            target = (org.activemq.ws.xmlbeans.resource.properties.QueryExpressionType)get_store().find_element_user(SELECTOR$0, 0);
            if (target == null)
            {
                return null;
            }
            return target;
        }
    }
    
    /**
     * Sets the "Selector" element
     */
    public void setSelector(org.activemq.ws.xmlbeans.resource.properties.QueryExpressionType selector)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.activemq.ws.xmlbeans.resource.properties.QueryExpressionType target = null;
            target = (org.activemq.ws.xmlbeans.resource.properties.QueryExpressionType)get_store().find_element_user(SELECTOR$0, 0);
            if (target == null)
            {
                target = (org.activemq.ws.xmlbeans.resource.properties.QueryExpressionType)get_store().add_element_user(SELECTOR$0);
            }
            target.set(selector);
        }
    }
    
    /**
     * Appends and returns a new empty "Selector" element
     */
    public org.activemq.ws.xmlbeans.resource.properties.QueryExpressionType addNewSelector()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.activemq.ws.xmlbeans.resource.properties.QueryExpressionType target = null;
            target = (org.activemq.ws.xmlbeans.resource.properties.QueryExpressionType)get_store().add_element_user(SELECTOR$0);
            return target;
        }
    }
}
