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

org.openehr.schemas.v1.impl.AUTHOREDRESOURCEImpl Maven / Gradle / Ivy

/*
 * XML Type:  AUTHORED_RESOURCE
 * Namespace: http://schemas.openehr.org/v1
 * Java type: org.openehr.schemas.v1.AUTHOREDRESOURCE
 *
 * Automatically generated - do not modify.
 */
package org.openehr.schemas.v1.impl;
/**
 * An XML AUTHORED_RESOURCE(@http://schemas.openehr.org/v1).
 *
 * This is a complex type.
 */
public class AUTHOREDRESOURCEImpl extends org.apache.xmlbeans.impl.values.XmlComplexContentImpl implements org.openehr.schemas.v1.AUTHOREDRESOURCE
{
    private static final long serialVersionUID = 1L;
    
    public AUTHOREDRESOURCEImpl(org.apache.xmlbeans.SchemaType sType)
    {
        super(sType);
    }
    
    private static final javax.xml.namespace.QName ORIGINALLANGUAGE$0 = 
        new javax.xml.namespace.QName("http://schemas.openehr.org/v1", "original_language");
    private static final javax.xml.namespace.QName ISCONTROLLED$2 = 
        new javax.xml.namespace.QName("http://schemas.openehr.org/v1", "is_controlled");
    private static final javax.xml.namespace.QName DESCRIPTION$4 = 
        new javax.xml.namespace.QName("http://schemas.openehr.org/v1", "description");
    private static final javax.xml.namespace.QName TRANSLATIONS$6 = 
        new javax.xml.namespace.QName("http://schemas.openehr.org/v1", "translations");
    private static final javax.xml.namespace.QName REVISIONHISTORY$8 = 
        new javax.xml.namespace.QName("http://schemas.openehr.org/v1", "revision_history");
    
    
    /**
     * Gets the "original_language" element
     */
    public org.openehr.schemas.v1.CODEPHRASE getOriginalLanguage()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.openehr.schemas.v1.CODEPHRASE target = null;
            target = (org.openehr.schemas.v1.CODEPHRASE)get_store().find_element_user(ORIGINALLANGUAGE$0, 0);
            if (target == null)
            {
                return null;
            }
            return target;
        }
    }
    
    /**
     * Sets the "original_language" element
     */
    public void setOriginalLanguage(org.openehr.schemas.v1.CODEPHRASE originalLanguage)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.openehr.schemas.v1.CODEPHRASE target = null;
            target = (org.openehr.schemas.v1.CODEPHRASE)get_store().find_element_user(ORIGINALLANGUAGE$0, 0);
            if (target == null)
            {
                target = (org.openehr.schemas.v1.CODEPHRASE)get_store().add_element_user(ORIGINALLANGUAGE$0);
            }
            target.set(originalLanguage);
        }
    }
    
    /**
     * Appends and returns a new empty "original_language" element
     */
    public org.openehr.schemas.v1.CODEPHRASE addNewOriginalLanguage()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.openehr.schemas.v1.CODEPHRASE target = null;
            target = (org.openehr.schemas.v1.CODEPHRASE)get_store().add_element_user(ORIGINALLANGUAGE$0);
            return target;
        }
    }
    
    /**
     * Gets the "is_controlled" element
     */
    public boolean getIsControlled()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(ISCONTROLLED$2, 0);
            if (target == null)
            {
                return false;
            }
            return target.getBooleanValue();
        }
    }
    
    /**
     * Gets (as xml) the "is_controlled" element
     */
    public org.apache.xmlbeans.XmlBoolean xgetIsControlled()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.XmlBoolean target = null;
            target = (org.apache.xmlbeans.XmlBoolean)get_store().find_element_user(ISCONTROLLED$2, 0);
            return target;
        }
    }
    
    /**
     * True if has "is_controlled" element
     */
    public boolean isSetIsControlled()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(ISCONTROLLED$2) != 0;
        }
    }
    
    /**
     * Sets the "is_controlled" element
     */
    public void setIsControlled(boolean isControlled)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(ISCONTROLLED$2, 0);
            if (target == null)
            {
                target = (org.apache.xmlbeans.SimpleValue)get_store().add_element_user(ISCONTROLLED$2);
            }
            target.setBooleanValue(isControlled);
        }
    }
    
    /**
     * Sets (as xml) the "is_controlled" element
     */
    public void xsetIsControlled(org.apache.xmlbeans.XmlBoolean isControlled)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.XmlBoolean target = null;
            target = (org.apache.xmlbeans.XmlBoolean)get_store().find_element_user(ISCONTROLLED$2, 0);
            if (target == null)
            {
                target = (org.apache.xmlbeans.XmlBoolean)get_store().add_element_user(ISCONTROLLED$2);
            }
            target.set(isControlled);
        }
    }
    
    /**
     * Unsets the "is_controlled" element
     */
    public void unsetIsControlled()
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(ISCONTROLLED$2, 0);
        }
    }
    
    /**
     * Gets the "description" element
     */
    public org.openehr.schemas.v1.RESOURCEDESCRIPTION getDescription()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.openehr.schemas.v1.RESOURCEDESCRIPTION target = null;
            target = (org.openehr.schemas.v1.RESOURCEDESCRIPTION)get_store().find_element_user(DESCRIPTION$4, 0);
            if (target == null)
            {
                return null;
            }
            return target;
        }
    }
    
    /**
     * True if has "description" element
     */
    public boolean isSetDescription()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(DESCRIPTION$4) != 0;
        }
    }
    
    /**
     * Sets the "description" element
     */
    public void setDescription(org.openehr.schemas.v1.RESOURCEDESCRIPTION description)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.openehr.schemas.v1.RESOURCEDESCRIPTION target = null;
            target = (org.openehr.schemas.v1.RESOURCEDESCRIPTION)get_store().find_element_user(DESCRIPTION$4, 0);
            if (target == null)
            {
                target = (org.openehr.schemas.v1.RESOURCEDESCRIPTION)get_store().add_element_user(DESCRIPTION$4);
            }
            target.set(description);
        }
    }
    
    /**
     * Appends and returns a new empty "description" element
     */
    public org.openehr.schemas.v1.RESOURCEDESCRIPTION addNewDescription()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.openehr.schemas.v1.RESOURCEDESCRIPTION target = null;
            target = (org.openehr.schemas.v1.RESOURCEDESCRIPTION)get_store().add_element_user(DESCRIPTION$4);
            return target;
        }
    }
    
    /**
     * Unsets the "description" element
     */
    public void unsetDescription()
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(DESCRIPTION$4, 0);
        }
    }
    
    /**
     * Gets array of all "translations" elements
     */
    public org.openehr.schemas.v1.TRANSLATIONDETAILS[] getTranslationsArray()
    {
        synchronized (monitor())
        {
            check_orphaned();
            java.util.List targetList = new java.util.ArrayList();
            get_store().find_all_element_users(TRANSLATIONS$6, targetList);
            org.openehr.schemas.v1.TRANSLATIONDETAILS[] result = new org.openehr.schemas.v1.TRANSLATIONDETAILS[targetList.size()];
            targetList.toArray(result);
            return result;
        }
    }
    
    /**
     * Gets ith "translations" element
     */
    public org.openehr.schemas.v1.TRANSLATIONDETAILS getTranslationsArray(int i)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.openehr.schemas.v1.TRANSLATIONDETAILS target = null;
            target = (org.openehr.schemas.v1.TRANSLATIONDETAILS)get_store().find_element_user(TRANSLATIONS$6, i);
            if (target == null)
            {
                throw new IndexOutOfBoundsException();
            }
            return target;
        }
    }
    
    /**
     * Returns number of "translations" element
     */
    public int sizeOfTranslationsArray()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(TRANSLATIONS$6);
        }
    }
    
    /**
     * Sets array of all "translations" element
     */
    public void setTranslationsArray(org.openehr.schemas.v1.TRANSLATIONDETAILS[] translationsArray)
    {
        synchronized (monitor())
        {
            check_orphaned();
            arraySetterHelper(translationsArray, TRANSLATIONS$6);
        }
    }
    
    /**
     * Sets ith "translations" element
     */
    public void setTranslationsArray(int i, org.openehr.schemas.v1.TRANSLATIONDETAILS translations)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.openehr.schemas.v1.TRANSLATIONDETAILS target = null;
            target = (org.openehr.schemas.v1.TRANSLATIONDETAILS)get_store().find_element_user(TRANSLATIONS$6, i);
            if (target == null)
            {
                throw new IndexOutOfBoundsException();
            }
            target.set(translations);
        }
    }
    
    /**
     * Inserts and returns a new empty value (as xml) as the ith "translations" element
     */
    public org.openehr.schemas.v1.TRANSLATIONDETAILS insertNewTranslations(int i)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.openehr.schemas.v1.TRANSLATIONDETAILS target = null;
            target = (org.openehr.schemas.v1.TRANSLATIONDETAILS)get_store().insert_element_user(TRANSLATIONS$6, i);
            return target;
        }
    }
    
    /**
     * Appends and returns a new empty value (as xml) as the last "translations" element
     */
    public org.openehr.schemas.v1.TRANSLATIONDETAILS addNewTranslations()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.openehr.schemas.v1.TRANSLATIONDETAILS target = null;
            target = (org.openehr.schemas.v1.TRANSLATIONDETAILS)get_store().add_element_user(TRANSLATIONS$6);
            return target;
        }
    }
    
    /**
     * Removes the ith "translations" element
     */
    public void removeTranslations(int i)
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(TRANSLATIONS$6, i);
        }
    }
    
    /**
     * Gets the "revision_history" element
     */
    public org.openehr.schemas.v1.REVISIONHISTORY getRevisionHistory()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.openehr.schemas.v1.REVISIONHISTORY target = null;
            target = (org.openehr.schemas.v1.REVISIONHISTORY)get_store().find_element_user(REVISIONHISTORY$8, 0);
            if (target == null)
            {
                return null;
            }
            return target;
        }
    }
    
    /**
     * True if has "revision_history" element
     */
    public boolean isSetRevisionHistory()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(REVISIONHISTORY$8) != 0;
        }
    }
    
    /**
     * Sets the "revision_history" element
     */
    public void setRevisionHistory(org.openehr.schemas.v1.REVISIONHISTORY revisionHistory)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.openehr.schemas.v1.REVISIONHISTORY target = null;
            target = (org.openehr.schemas.v1.REVISIONHISTORY)get_store().find_element_user(REVISIONHISTORY$8, 0);
            if (target == null)
            {
                target = (org.openehr.schemas.v1.REVISIONHISTORY)get_store().add_element_user(REVISIONHISTORY$8);
            }
            target.set(revisionHistory);
        }
    }
    
    /**
     * Appends and returns a new empty "revision_history" element
     */
    public org.openehr.schemas.v1.REVISIONHISTORY addNewRevisionHistory()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.openehr.schemas.v1.REVISIONHISTORY target = null;
            target = (org.openehr.schemas.v1.REVISIONHISTORY)get_store().add_element_user(REVISIONHISTORY$8);
            return target;
        }
    }
    
    /**
     * Unsets the "revision_history" element
     */
    public void unsetRevisionHistory()
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(REVISIONHISTORY$8, 0);
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy