Package org.apache.xmlbeans.impl.values
Class XmlUnionImpl
- java.lang.Object
-
- org.apache.xmlbeans.impl.values.XmlObjectBase
-
- org.apache.xmlbeans.impl.values.XmlUnionImpl
-
- All Implemented Interfaces:
java.io.Serializable
,TypeStoreUser
,SimpleValue
,XmlAnySimpleType
,XmlObject
,XmlTokenSource
- Direct Known Subclasses:
AllImpl.MaxOccursImpl
,AllNNIImpl
,BlockSetImpl
,DerivationSetImpl
,FullDerivationSetImpl
,JavaNameListImpl
,NamespaceListImpl
,NamespaceListImpl
,NamespaceListImpl.MemberImpl2.ItemImpl
,NamespaceListImpl.MemberImpl2.ItemImpl
,NarrowMaxMinImpl.MaxOccursImpl
,SimpleDerivationSetImpl
public class XmlUnionImpl extends XmlObjectBase implements XmlAnySimpleType
This class implements simple union types.- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.apache.xmlbeans.XmlAnySimpleType
XmlAnySimpleType.Factory
-
Nested classes/interfaces inherited from interface org.apache.xmlbeans.XmlObject
XmlObject.Factory
-
-
Field Summary
-
Fields inherited from class org.apache.xmlbeans.impl.values.XmlObjectBase
_voorVc, KIND_SETTERHELPER_ARRAYITEM, KIND_SETTERHELPER_SINGLETON, MAJOR_VERSION_NUMBER, MINOR_VERSION_NUMBER
-
Fields inherited from interface org.apache.xmlbeans.XmlAnySimpleType
type
-
-
Constructor Summary
Constructors Constructor Description XmlUnionImpl(SchemaType type, boolean complex)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.math.BigDecimal
getBigDecimalValue()
Returns the value as aBigDecimal
.java.math.BigInteger
getBigIntegerValue()
Returns the value as aBigInteger
.boolean
getBooleanValue()
Returns the value as a boolean.byte[]
getByteArrayValue()
Returns the value as a byte array.byte
getByteValue()
Returns the value as a byte.java.util.Calendar
getCalendarValue()
Returns the value as aCalendar
.java.util.Date
getDateValue()
Returns the value as aDate
.double
getDoubleValue()
Returns the value as a double.StringEnumAbstractBase
getEnumValue()
Returns the value as aStringEnumAbstractBase
.float
getFloatValue()
Returns the value as a float.GDate
getGDateValue()
Returns the value as aGDate
.GDuration
getGDurationValue()
Returns the value as aGDuration
.int
getIntValue()
Returns the value as an int.java.util.List
getListValue()
Returns the value as aList
of friendly Java objects (String, Integer, Byte, Short, Long, BigInteger, Decimal, Float, Double, byte[], Calendar, GDuration).long
getLongValue()
Returns the value as a long.javax.xml.namespace.QName
getQNameValue()
Returns the value as aQName
.short
getShortValue()
Returns the value as a short.java.lang.String
getStringValue()
Returns the value as aString
.SchemaType
instanceType()
The same as getSchemaType unless this is a union instance or nil value.SchemaType
schemaType()
java.util.List
xgetListValue()
Returns the value as aList
of XmlAnySimpleType objects.-
Methods inherited from class org.apache.xmlbeans.impl.values.XmlObjectBase
_copy, _copy, _set, attach_store, bigDecimalValue, bigIntegerValue, booleanValue, build_nil, build_text, byteArrayValue, byteValue, calendarValue, changeType, check_dated, compareTo, compareValue, copy, copy, create_attribute_user, create_element_user, dateValue, disconnect_store, documentProperties, doubleValue, dump, enumValue, equals, execQuery, execQuery, floatValue, gDateValue, gDurationValue, generatedSetterHelperImpl, get_attribute_field, get_attribute_type, get_attributeflags, get_default_attribute_text, get_default_element_text, get_element_ending_delimiters, get_element_type, get_elementflags, get_schema_type, get_store, get_wscanon_text, getDomNode, getObjectValue, getXmlLocale, hashCode, init_flags, intValue, invalidate_element_order, invalidate_nilvalue, invalidate_value, is_child_element_order_sensitive, isDefault, isDefaultable, isFixed, isImmutable, isInstanceOf, isNil, isNillable, listValue, longValue, monitor, new_visitor, newCursor, newCursorForce, newDomNode, newDomNode, newInputStream, newInputStream, newReader, newReader, newXMLInputStream, newXMLInputStream, newXMLStreamReader, newXMLStreamReader, objectSet, objectValue, qNameValue, save, save, save, save, save, save, save, save, selectAttribute, selectAttribute, selectAttributes, selectChildren, selectChildren, selectChildren, selectPath, selectPath, set, set, set, set, set, set, set, set, set, set, set, set, set, set, set, set, set, set, set, set_newValue, setBigDecimalValue, setBigIntegerValue, setBooleanValue, setByteArrayValue, setByteValue, setCalendarValue, setDateValue, setDoubleValue, setEnumValue, setFloatValue, setGDateValue, setGDateValue, setGDurationValue, setGDurationValue, setImmutable, setIntValue, setListValue, setLongValue, setNil, setObjectValue, setQNameValue, setShortValue, setStringValue, setValidateOnSet, shortValue, stringValue, substitute, toString, uses_invalidate_value, validate, validate, validate_now, valueEquals, valueHashCode, writeReplace, xlistValue, xmlText, xmlText
-
Methods inherited from interface org.apache.xmlbeans.XmlAnySimpleType
set, setStringValue, stringValue
-
Methods inherited from interface org.apache.xmlbeans.XmlObject
changeType, compareTo, compareValue, copy, copy, execQuery, execQuery, isImmutable, isNil, selectAttribute, selectAttribute, selectAttributes, selectChildren, selectChildren, selectChildren, selectPath, selectPath, set, setNil, substitute, toString, validate, validate, valueEquals, valueHashCode
-
Methods inherited from interface org.apache.xmlbeans.XmlTokenSource
documentProperties, dump, getDomNode, monitor, newCursor, newDomNode, newDomNode, newInputStream, newInputStream, newReader, newReader, newXMLInputStream, newXMLInputStream, newXMLStreamReader, newXMLStreamReader, save, save, save, save, save, save, save, save, xmlText, xmlText
-
-
-
-
Constructor Detail
-
XmlUnionImpl
public XmlUnionImpl(SchemaType type, boolean complex)
-
-
Method Detail
-
schemaType
public SchemaType schemaType()
- Specified by:
schemaType
in interfaceXmlObject
- Specified by:
schemaType
in classXmlObjectBase
- Returns:
- The schema type for this instance. This is a permanent, unchanging property of the instance.
-
instanceType
public SchemaType instanceType()
Description copied from interface:SimpleValue
The same as getSchemaType unless this is a union instance or nil value.For unions, this returns the non-union consituent type of this instance. This type may change if setters are called that cause the instance to change to another constituent type of the union.
For nil values, this returns null.
- Specified by:
instanceType
in interfaceSimpleValue
- Overrides:
instanceType
in classXmlObjectBase
-
getFloatValue
public float getFloatValue()
Description copied from interface:SimpleValue
Returns the value as a float.- Specified by:
getFloatValue
in interfaceSimpleValue
- Overrides:
getFloatValue
in classXmlObjectBase
-
getDoubleValue
public double getDoubleValue()
Description copied from interface:SimpleValue
Returns the value as a double.- Specified by:
getDoubleValue
in interfaceSimpleValue
- Overrides:
getDoubleValue
in classXmlObjectBase
-
getBigDecimalValue
public java.math.BigDecimal getBigDecimalValue()
Description copied from interface:SimpleValue
Returns the value as aBigDecimal
.- Specified by:
getBigDecimalValue
in interfaceSimpleValue
- Overrides:
getBigDecimalValue
in classXmlObjectBase
-
getBigIntegerValue
public java.math.BigInteger getBigIntegerValue()
Description copied from interface:SimpleValue
Returns the value as aBigInteger
.- Specified by:
getBigIntegerValue
in interfaceSimpleValue
- Overrides:
getBigIntegerValue
in classXmlObjectBase
-
getByteValue
public byte getByteValue()
Description copied from interface:SimpleValue
Returns the value as a byte.- Specified by:
getByteValue
in interfaceSimpleValue
- Overrides:
getByteValue
in classXmlObjectBase
-
getShortValue
public short getShortValue()
Description copied from interface:SimpleValue
Returns the value as a short.- Specified by:
getShortValue
in interfaceSimpleValue
- Overrides:
getShortValue
in classXmlObjectBase
-
getIntValue
public int getIntValue()
Description copied from interface:SimpleValue
Returns the value as an int.- Specified by:
getIntValue
in interfaceSimpleValue
- Overrides:
getIntValue
in classXmlObjectBase
-
getLongValue
public long getLongValue()
Description copied from interface:SimpleValue
Returns the value as a long.- Specified by:
getLongValue
in interfaceSimpleValue
- Overrides:
getLongValue
in classXmlObjectBase
-
getByteArrayValue
public byte[] getByteArrayValue()
Description copied from interface:SimpleValue
Returns the value as a byte array.- Specified by:
getByteArrayValue
in interfaceSimpleValue
- Overrides:
getByteArrayValue
in classXmlObjectBase
-
getBooleanValue
public boolean getBooleanValue()
Description copied from interface:SimpleValue
Returns the value as a boolean.- Specified by:
getBooleanValue
in interfaceSimpleValue
- Overrides:
getBooleanValue
in classXmlObjectBase
-
getCalendarValue
public java.util.Calendar getCalendarValue()
Description copied from interface:SimpleValue
Returns the value as aCalendar
.- Specified by:
getCalendarValue
in interfaceSimpleValue
- Overrides:
getCalendarValue
in classXmlObjectBase
-
getDateValue
public java.util.Date getDateValue()
Description copied from interface:SimpleValue
Returns the value as aDate
.- Specified by:
getDateValue
in interfaceSimpleValue
- Overrides:
getDateValue
in classXmlObjectBase
-
getGDateValue
public GDate getGDateValue()
Description copied from interface:SimpleValue
Returns the value as aGDate
.- Specified by:
getGDateValue
in interfaceSimpleValue
- Overrides:
getGDateValue
in classXmlObjectBase
-
getGDurationValue
public GDuration getGDurationValue()
Description copied from interface:SimpleValue
Returns the value as aGDuration
.- Specified by:
getGDurationValue
in interfaceSimpleValue
- Overrides:
getGDurationValue
in classXmlObjectBase
-
getQNameValue
public javax.xml.namespace.QName getQNameValue()
Description copied from interface:SimpleValue
Returns the value as aQName
.- Specified by:
getQNameValue
in interfaceSimpleValue
- Overrides:
getQNameValue
in classXmlObjectBase
-
getListValue
public java.util.List getListValue()
Description copied from interface:SimpleValue
Returns the value as aList
of friendly Java objects (String, Integer, Byte, Short, Long, BigInteger, Decimal, Float, Double, byte[], Calendar, GDuration).- Specified by:
getListValue
in interfaceSimpleValue
- Overrides:
getListValue
in classXmlObjectBase
-
xgetListValue
public java.util.List xgetListValue()
Description copied from interface:SimpleValue
Returns the value as aList
of XmlAnySimpleType objects.- Specified by:
xgetListValue
in interfaceSimpleValue
- Overrides:
xgetListValue
in classXmlObjectBase
-
getEnumValue
public StringEnumAbstractBase getEnumValue()
Description copied from interface:SimpleValue
Returns the value as aStringEnumAbstractBase
.- Specified by:
getEnumValue
in interfaceSimpleValue
- Overrides:
getEnumValue
in classXmlObjectBase
-
getStringValue
public java.lang.String getStringValue()
Description copied from interface:SimpleValue
Returns the value as aString
.- Specified by:
getStringValue
in interfaceSimpleValue
- Specified by:
getStringValue
in interfaceXmlAnySimpleType
- Overrides:
getStringValue
in classXmlObjectBase
-
-