net.opengis.ows.x11.impl.AllowedValuesDocumentImpl Maven / Gradle / Ivy
The newest version!
/*
* An XML document type.
* Localname: AllowedValues
* Namespace: http://www.opengis.net/ows/1.1
* Java type: net.opengis.ows.x11.AllowedValuesDocument
*
* Automatically generated - do not modify.
*/
package net.opengis.ows.x11.impl;
import javax.xml.namespace.QName;
import org.apache.xmlbeans.QNameSet;
import org.apache.xmlbeans.XmlObject;
/**
* A document containing one AllowedValues(@http://www.opengis.net/ows/1.1) element.
*
* This is a complex type.
*/
public class AllowedValuesDocumentImpl extends org.apache.xmlbeans.impl.values.XmlComplexContentImpl implements net.opengis.ows.x11.AllowedValuesDocument {
private static final long serialVersionUID = 1L;
public AllowedValuesDocumentImpl(org.apache.xmlbeans.SchemaType sType) {
super(sType);
}
private static final QName[] PROPERTY_QNAME = {
new QName("http://www.opengis.net/ows/1.1", "AllowedValues"),
};
/**
* Gets the "AllowedValues" element
*/
@Override
public net.opengis.ows.x11.AllowedValuesDocument.AllowedValues getAllowedValues() {
synchronized (monitor()) {
check_orphaned();
net.opengis.ows.x11.AllowedValuesDocument.AllowedValues target = null;
target = (net.opengis.ows.x11.AllowedValuesDocument.AllowedValues)get_store().find_element_user(PROPERTY_QNAME[0], 0);
return (target == null) ? null : target;
}
}
/**
* Sets the "AllowedValues" element
*/
@Override
public void setAllowedValues(net.opengis.ows.x11.AllowedValuesDocument.AllowedValues allowedValues) {
generatedSetterHelperImpl(allowedValues, PROPERTY_QNAME[0], 0, org.apache.xmlbeans.impl.values.XmlObjectBase.KIND_SETTERHELPER_SINGLETON);
}
/**
* Appends and returns a new empty "AllowedValues" element
*/
@Override
public net.opengis.ows.x11.AllowedValuesDocument.AllowedValues addNewAllowedValues() {
synchronized (monitor()) {
check_orphaned();
net.opengis.ows.x11.AllowedValuesDocument.AllowedValues target = null;
target = (net.opengis.ows.x11.AllowedValuesDocument.AllowedValues)get_store().add_element_user(PROPERTY_QNAME[0]);
return target;
}
}
/**
* An XML AllowedValues(@http://www.opengis.net/ows/1.1).
*
* This is a complex type.
*/
public static class AllowedValuesImpl extends org.apache.xmlbeans.impl.values.XmlComplexContentImpl implements net.opengis.ows.x11.AllowedValuesDocument.AllowedValues {
private static final long serialVersionUID = 1L;
public AllowedValuesImpl(org.apache.xmlbeans.SchemaType sType) {
super(sType);
}
private static final QName[] PROPERTY_QNAME = {
new QName("http://www.opengis.net/ows/1.1", "Value"),
new QName("http://www.opengis.net/ows/1.1", "Range"),
};
/**
* Gets a List of "Value" elements
*/
@Override
public java.util.List getValueList() {
synchronized (monitor()) {
check_orphaned();
return new org.apache.xmlbeans.impl.values.JavaListXmlObject<>(
this::getValueArray,
this::setValueArray,
this::insertNewValue,
this::removeValue,
this::sizeOfValueArray
);
}
}
/**
* Gets array of all "Value" elements
*/
@Override
public net.opengis.ows.x11.ValueType[] getValueArray() {
return getXmlObjectArray(PROPERTY_QNAME[0], new net.opengis.ows.x11.ValueType[0]);
}
/**
* Gets ith "Value" element
*/
@Override
public net.opengis.ows.x11.ValueType getValueArray(int i) {
synchronized (monitor()) {
check_orphaned();
net.opengis.ows.x11.ValueType target = null;
target = (net.opengis.ows.x11.ValueType)get_store().find_element_user(PROPERTY_QNAME[0], i);
if (target == null) {
throw new IndexOutOfBoundsException();
}
return target;
}
}
/**
* Returns number of "Value" element
*/
@Override
public int sizeOfValueArray() {
synchronized (monitor()) {
check_orphaned();
return get_store().count_elements(PROPERTY_QNAME[0]);
}
}
/**
* Sets array of all "Value" element WARNING: This method is not atomicaly synchronized.
*/
@Override
public void setValueArray(net.opengis.ows.x11.ValueType[] valueArray) {
check_orphaned();
arraySetterHelper(valueArray, PROPERTY_QNAME[0]);
}
/**
* Sets ith "Value" element
*/
@Override
public void setValueArray(int i, net.opengis.ows.x11.ValueType value) {
generatedSetterHelperImpl(value, PROPERTY_QNAME[0], i, org.apache.xmlbeans.impl.values.XmlObjectBase.KIND_SETTERHELPER_ARRAYITEM);
}
/**
* Inserts and returns a new empty value (as xml) as the ith "Value" element
*/
@Override
public net.opengis.ows.x11.ValueType insertNewValue(int i) {
synchronized (monitor()) {
check_orphaned();
net.opengis.ows.x11.ValueType target = null;
target = (net.opengis.ows.x11.ValueType)get_store().insert_element_user(PROPERTY_QNAME[0], i);
return target;
}
}
/**
* Appends and returns a new empty value (as xml) as the last "Value" element
*/
@Override
public net.opengis.ows.x11.ValueType addNewValue() {
synchronized (monitor()) {
check_orphaned();
net.opengis.ows.x11.ValueType target = null;
target = (net.opengis.ows.x11.ValueType)get_store().add_element_user(PROPERTY_QNAME[0]);
return target;
}
}
/**
* Removes the ith "Value" element
*/
@Override
public void removeValue(int i) {
synchronized (monitor()) {
check_orphaned();
get_store().remove_element(PROPERTY_QNAME[0], i);
}
}
/**
* Gets a List of "Range" elements
*/
@Override
public java.util.List getRangeList() {
synchronized (monitor()) {
check_orphaned();
return new org.apache.xmlbeans.impl.values.JavaListXmlObject<>(
this::getRangeArray,
this::setRangeArray,
this::insertNewRange,
this::removeRange,
this::sizeOfRangeArray
);
}
}
/**
* Gets array of all "Range" elements
*/
@Override
public net.opengis.ows.x11.RangeType[] getRangeArray() {
return getXmlObjectArray(PROPERTY_QNAME[1], new net.opengis.ows.x11.RangeType[0]);
}
/**
* Gets ith "Range" element
*/
@Override
public net.opengis.ows.x11.RangeType getRangeArray(int i) {
synchronized (monitor()) {
check_orphaned();
net.opengis.ows.x11.RangeType target = null;
target = (net.opengis.ows.x11.RangeType)get_store().find_element_user(PROPERTY_QNAME[1], i);
if (target == null) {
throw new IndexOutOfBoundsException();
}
return target;
}
}
/**
* Returns number of "Range" element
*/
@Override
public int sizeOfRangeArray() {
synchronized (monitor()) {
check_orphaned();
return get_store().count_elements(PROPERTY_QNAME[1]);
}
}
/**
* Sets array of all "Range" element WARNING: This method is not atomicaly synchronized.
*/
@Override
public void setRangeArray(net.opengis.ows.x11.RangeType[] rangeArray) {
check_orphaned();
arraySetterHelper(rangeArray, PROPERTY_QNAME[1]);
}
/**
* Sets ith "Range" element
*/
@Override
public void setRangeArray(int i, net.opengis.ows.x11.RangeType range) {
generatedSetterHelperImpl(range, PROPERTY_QNAME[1], i, org.apache.xmlbeans.impl.values.XmlObjectBase.KIND_SETTERHELPER_ARRAYITEM);
}
/**
* Inserts and returns a new empty value (as xml) as the ith "Range" element
*/
@Override
public net.opengis.ows.x11.RangeType insertNewRange(int i) {
synchronized (monitor()) {
check_orphaned();
net.opengis.ows.x11.RangeType target = null;
target = (net.opengis.ows.x11.RangeType)get_store().insert_element_user(PROPERTY_QNAME[1], i);
return target;
}
}
/**
* Appends and returns a new empty value (as xml) as the last "Range" element
*/
@Override
public net.opengis.ows.x11.RangeType addNewRange() {
synchronized (monitor()) {
check_orphaned();
net.opengis.ows.x11.RangeType target = null;
target = (net.opengis.ows.x11.RangeType)get_store().add_element_user(PROPERTY_QNAME[1]);
return target;
}
}
/**
* Removes the ith "Range" element
*/
@Override
public void removeRange(int i) {
synchronized (monitor()) {
check_orphaned();
get_store().remove_element(PROPERTY_QNAME[1], i);
}
}
}
}