|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.sun.tools.xjc.model.CPropertyInfo
com.sun.tools.xjc.model.CElementPropertyInfo
public final class CElementPropertyInfo
ElementPropertyInfo for the compiler.
| Nested Class Summary | |
|---|---|
static class |
CElementPropertyInfo.CollectionMode
|
| Field Summary |
|---|
| Fields inherited from class com.sun.tools.xjc.model.CPropertyInfo |
|---|
baseType, defaultValue, inlineBinaryData, javadoc, locator, realization |
| Constructor Summary | |
|---|---|
CElementPropertyInfo(String name,
CElementPropertyInfo.CollectionMode collection,
com.sun.xml.bind.v2.model.core.ID id,
MimeType expectedMimeType,
XSComponent source,
CCustomizations customizations,
Locator locator,
boolean required)
|
|
| Method Summary | ||
|---|---|---|
|
accept(CPropertyVisitor<V> visitor)
|
|
QName |
collectElementNames(Map<QName,CPropertyInfo> table)
Puts the element names that this property possesses to the map, so that we can find two properties that own the same element name, which is an error. |
|
CAdapter |
getAdapter()
|
|
MimeType |
getExpectedMimeType()
|
|
QName |
getSchemaType()
|
|
List<CTypeRef> |
getTypes()
|
|
QName |
getXmlName()
Deprecated. |
|
com.sun.xml.bind.v2.model.core.ID |
id()
|
|
boolean |
isCollectionNillable()
|
|
boolean |
isCollectionRequired()
|
|
boolean |
isOptionalPrimitive()
Returns true if this property needs to represent null just for the purpose of representing an absence of the property. |
|
boolean |
isRequired()
|
|
boolean |
isUnboxable()
Returns true if this property is "unboxable". |
|
boolean |
isValueList()
|
|
com.sun.xml.bind.v2.model.core.PropertyKind |
kind()
|
|
List<CNonElement> |
ref()
|
|
void |
setAdapter(CAdapter a)
|
|
| Methods inherited from class com.sun.tools.xjc.model.CPropertyInfo |
|---|
displayName, getCustomizations, getLocator, getName, getName, getSchemaComponent, hasAnnotation, inlineBinaryData, isCollection, needsExplicitTypeName, parent, readAnnotation, setName |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface com.sun.xml.bind.v2.model.core.PropertyInfo |
|---|
displayName, getName, inlineBinaryData, isCollection, parent |
| Methods inherited from interface com.sun.xml.bind.v2.model.annotation.AnnotationSource |
|---|
hasAnnotation, readAnnotation |
| Constructor Detail |
|---|
public CElementPropertyInfo(String name,
CElementPropertyInfo.CollectionMode collection,
com.sun.xml.bind.v2.model.core.ID id,
MimeType expectedMimeType,
XSComponent source,
CCustomizations customizations,
Locator locator,
boolean required)
| Method Detail |
|---|
public com.sun.xml.bind.v2.model.core.ID id()
id in interface com.sun.xml.bind.v2.model.core.PropertyInfo<NType,NClass>public List<CTypeRef> getTypes()
getTypes in interface com.sun.xml.bind.v2.model.core.ElementPropertyInfo<NType,NClass>public List<CNonElement> ref()
ref in interface com.sun.xml.bind.v2.model.core.PropertyInfo<NType,NClass>ref in class CPropertyInfopublic QName getSchemaType()
getSchemaType in interface com.sun.xml.bind.v2.model.core.PropertyInfo<NType,NClass>@Deprecated public QName getXmlName()
getXmlName in interface com.sun.xml.bind.v2.model.core.ElementPropertyInfo<NType,NClass>public boolean isCollectionRequired()
isCollectionRequired in interface com.sun.xml.bind.v2.model.core.ElementPropertyInfo<NType,NClass>public boolean isCollectionNillable()
isCollectionNillable in interface com.sun.xml.bind.v2.model.core.ElementPropertyInfo<NType,NClass>public boolean isRequired()
isRequired in interface com.sun.xml.bind.v2.model.core.ElementPropertyInfo<NType,NClass>public boolean isValueList()
isValueList in interface com.sun.xml.bind.v2.model.core.ElementPropertyInfo<NType,NClass>public boolean isUnboxable()
CPropertyInfoIn general, a property often has to be capable of representing null to indicate the absence of the value. This requires properties to be generated as @XmlElement Float f, not as @XmlElement float f;. But this is slow.
Fortunately, there are cases where we know that the property can never legally be absent. When this condition holds we can generate the optimized "unboxed form".
The exact such conditions depend on the kind of properties, so refer to the implementation code for the details.
This method returns true when the property can be generated as "unboxed form", false otherwise.
When this property is a collection, this method returns true if items in the collection is unboxable. Obviously, the collection itself is always a reference type.
isUnboxable in class CPropertyInfopublic boolean isOptionalPrimitive()
CPropertyInfo
isOptionalPrimitive in class CPropertyInfopublic <V> V accept(CPropertyVisitor<V> visitor)
accept in class CPropertyInfopublic CAdapter getAdapter()
getAdapter in interface com.sun.xml.bind.v2.model.core.ElementPropertyInfo<NType,NClass>getAdapter in interface com.sun.xml.bind.v2.model.core.PropertyInfo<NType,NClass>getAdapter in class CPropertyInfopublic void setAdapter(CAdapter a)
public final com.sun.xml.bind.v2.model.core.PropertyKind kind()
kind in interface com.sun.xml.bind.v2.model.core.PropertyInfo<NType,NClass>public MimeType getExpectedMimeType()
getExpectedMimeType in interface com.sun.xml.bind.v2.model.core.PropertyInfo<NType,NClass>public QName collectElementNames(Map<QName,CPropertyInfo> table)
CPropertyInfo
collectElementNames in class CPropertyInfo
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||