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

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

/*
 * XML Type:  INTERVAL_EVENT
 * Namespace: http://schemas.openehr.org/v1
 * Java type: org.openehr.schemas.v1.INTERVALEVENT
 *
 * Automatically generated - do not modify.
 */
package org.openehr.schemas.v1.impl;
/**
 * An XML INTERVAL_EVENT(@http://schemas.openehr.org/v1).
 *
 * This is a complex type.
 */
public class INTERVALEVENTImpl extends org.openehr.schemas.v1.impl.EVENTImpl implements org.openehr.schemas.v1.INTERVALEVENT
{
    private static final long serialVersionUID = 1L;
    
    public INTERVALEVENTImpl(org.apache.xmlbeans.SchemaType sType)
    {
        super(sType);
    }
    
    private static final javax.xml.namespace.QName WIDTH$0 = 
        new javax.xml.namespace.QName("http://schemas.openehr.org/v1", "width");
    private static final javax.xml.namespace.QName SAMPLECOUNT$2 = 
        new javax.xml.namespace.QName("http://schemas.openehr.org/v1", "sample_count");
    private static final javax.xml.namespace.QName MATHFUNCTION$4 = 
        new javax.xml.namespace.QName("http://schemas.openehr.org/v1", "math_function");
    
    
    /**
     * Gets the "width" element
     */
    public org.openehr.schemas.v1.DVDURATION getWidth()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.openehr.schemas.v1.DVDURATION target = null;
            target = (org.openehr.schemas.v1.DVDURATION)get_store().find_element_user(WIDTH$0, 0);
            if (target == null)
            {
                return null;
            }
            return target;
        }
    }
    
    /**
     * Sets the "width" element
     */
    public void setWidth(org.openehr.schemas.v1.DVDURATION width)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.openehr.schemas.v1.DVDURATION target = null;
            target = (org.openehr.schemas.v1.DVDURATION)get_store().find_element_user(WIDTH$0, 0);
            if (target == null)
            {
                target = (org.openehr.schemas.v1.DVDURATION)get_store().add_element_user(WIDTH$0);
            }
            target.set(width);
        }
    }
    
    /**
     * Appends and returns a new empty "width" element
     */
    public org.openehr.schemas.v1.DVDURATION addNewWidth()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.openehr.schemas.v1.DVDURATION target = null;
            target = (org.openehr.schemas.v1.DVDURATION)get_store().add_element_user(WIDTH$0);
            return target;
        }
    }
    
    /**
     * Gets the "sample_count" element
     */
    public int getSampleCount()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(SAMPLECOUNT$2, 0);
            if (target == null)
            {
                return 0;
            }
            return target.getIntValue();
        }
    }
    
    /**
     * Gets (as xml) the "sample_count" element
     */
    public org.apache.xmlbeans.XmlInt xgetSampleCount()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.XmlInt target = null;
            target = (org.apache.xmlbeans.XmlInt)get_store().find_element_user(SAMPLECOUNT$2, 0);
            return target;
        }
    }
    
    /**
     * True if has "sample_count" element
     */
    public boolean isSetSampleCount()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(SAMPLECOUNT$2) != 0;
        }
    }
    
    /**
     * Sets the "sample_count" element
     */
    public void setSampleCount(int sampleCount)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(SAMPLECOUNT$2, 0);
            if (target == null)
            {
                target = (org.apache.xmlbeans.SimpleValue)get_store().add_element_user(SAMPLECOUNT$2);
            }
            target.setIntValue(sampleCount);
        }
    }
    
    /**
     * Sets (as xml) the "sample_count" element
     */
    public void xsetSampleCount(org.apache.xmlbeans.XmlInt sampleCount)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.XmlInt target = null;
            target = (org.apache.xmlbeans.XmlInt)get_store().find_element_user(SAMPLECOUNT$2, 0);
            if (target == null)
            {
                target = (org.apache.xmlbeans.XmlInt)get_store().add_element_user(SAMPLECOUNT$2);
            }
            target.set(sampleCount);
        }
    }
    
    /**
     * Unsets the "sample_count" element
     */
    public void unsetSampleCount()
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(SAMPLECOUNT$2, 0);
        }
    }
    
    /**
     * Gets the "math_function" element
     */
    public org.openehr.schemas.v1.DVCODEDTEXT getMathFunction()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.openehr.schemas.v1.DVCODEDTEXT target = null;
            target = (org.openehr.schemas.v1.DVCODEDTEXT)get_store().find_element_user(MATHFUNCTION$4, 0);
            if (target == null)
            {
                return null;
            }
            return target;
        }
    }
    
    /**
     * Sets the "math_function" element
     */
    public void setMathFunction(org.openehr.schemas.v1.DVCODEDTEXT mathFunction)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.openehr.schemas.v1.DVCODEDTEXT target = null;
            target = (org.openehr.schemas.v1.DVCODEDTEXT)get_store().find_element_user(MATHFUNCTION$4, 0);
            if (target == null)
            {
                target = (org.openehr.schemas.v1.DVCODEDTEXT)get_store().add_element_user(MATHFUNCTION$4);
            }
            target.set(mathFunction);
        }
    }
    
    /**
     * Appends and returns a new empty "math_function" element
     */
    public org.openehr.schemas.v1.DVCODEDTEXT addNewMathFunction()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.openehr.schemas.v1.DVCODEDTEXT target = null;
            target = (org.openehr.schemas.v1.DVCODEDTEXT)get_store().add_element_user(MATHFUNCTION$4);
            return target;
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy