Package com.sun.tools.xjc.model
Class CReferencePropertyInfo
java.lang.Object
com.sun.tools.xjc.model.CPropertyInfo
com.sun.tools.xjc.model.CReferencePropertyInfo
- All Implemented Interfaces:
CCustomizable
,AnnotationSource
,PropertyInfo<NType,
,NClass> ReferencePropertyInfo<NType,
NClass>
public final class CReferencePropertyInfo
extends CPropertyInfo
implements ReferencePropertyInfo<NType,NClass>
ReferencePropertyInfo
for the compiler.- Author:
- Kohsuke Kawaguchi
-
Field Summary
Fields inherited from class com.sun.tools.xjc.model.CPropertyInfo
baseType, defaultValue, inlineBinaryData, javadoc, locator, realization
-
Constructor Summary
ConstructorDescriptionCReferencePropertyInfo
(String name, boolean collection, boolean required, boolean isMixed, XSComponent source, CCustomizations customizations, Locator locator, boolean dummy, boolean content, boolean isMixedExtended) -
Method Summary
Modifier and TypeMethodDescription<V> V
accept
(CPropertyVisitor<V> visitor) <R,
P> R accept
(CPropertyVisitor2<R, P> visitor, P p) 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.Deprecated.id()
A reference property can never be ID/IDREF because they always point to other element classes.boolean
boolean
boolean
boolean
isDummy()
boolean
isMixed()
boolean
boolean
Returns true if this property needs to represent null just for the purpose of representing an absence of the property.boolean
boolean
Reference properties refer to elements, and none of the Java primitive type maps to an element.kind()
ref()
void
setWildcard
(WildcardMode mode) 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 org.glassfish.jaxb.core.v2.model.annotation.AnnotationSource
hasAnnotation, readAnnotation
Methods inherited from interface org.glassfish.jaxb.core.v2.model.core.PropertyInfo
displayName, getName, inlineBinaryData, isCollection, parent
-
Constructor Details
-
CReferencePropertyInfo
public CReferencePropertyInfo(String name, boolean collection, boolean required, boolean isMixed, XSComponent source, CCustomizations customizations, Locator locator, boolean dummy, boolean content, boolean isMixedExtended)
-
-
Method Details
-
ref
- Specified by:
ref
in interfacePropertyInfo<NType,
NClass> - Specified by:
ref
in interfaceReferencePropertyInfo<NType,
NClass> - Specified by:
ref
in classCPropertyInfo
-
getElements
- Specified by:
getElements
in interfaceReferencePropertyInfo<NType,
NClass>
-
isMixed
public boolean isMixed()- Specified by:
isMixed
in interfaceReferencePropertyInfo<NType,
NClass>
-
isDummy
public boolean isDummy() -
isContent
public boolean isContent() -
isMixedExtendedCust
public boolean isMixedExtendedCust() -
getXmlName
Deprecated.We'll never use a wrapper element in XJC. Always return null.- Specified by:
getXmlName
in interfaceReferencePropertyInfo<NType,
NClass>
-
isUnboxable
public boolean isUnboxable()Reference properties refer to elements, and none of the Java primitive type maps to an element. Thus a reference property is always unboxable.- Overrides:
isUnboxable
in classCPropertyInfo
-
isOptionalPrimitive
public boolean isOptionalPrimitive()Description copied from class:CPropertyInfo
Returns true if this property needs to represent null just for the purpose of representing an absence of the property.- Overrides:
isOptionalPrimitive
in classCPropertyInfo
-
accept
- Specified by:
accept
in classCPropertyInfo
-
accept
- Specified by:
accept
in classCPropertyInfo
-
getAdapter
- Specified by:
getAdapter
in interfacePropertyInfo<NType,
NClass> - Specified by:
getAdapter
in interfaceReferencePropertyInfo<NType,
NClass> - Specified by:
getAdapter
in classCPropertyInfo
-
kind
- Specified by:
kind
in interfacePropertyInfo<NType,
NClass>
-
id
A reference property can never be ID/IDREF because they always point to other element classes.- Specified by:
id
in interfacePropertyInfo<NType,
NClass>
-
getWildcard
- Specified by:
getWildcard
in interfaceReferencePropertyInfo<NType,
NClass>
-
setWildcard
-
getDOMHandler
- Specified by:
getDOMHandler
in interfaceReferencePropertyInfo<NType,
NClass>
-
getExpectedMimeType
- Specified by:
getExpectedMimeType
in interfacePropertyInfo<NType,
NClass>
-
isCollectionNillable
public boolean isCollectionNillable()- Specified by:
isCollectionNillable
in interfaceReferencePropertyInfo<NType,
NClass>
-
isCollectionRequired
public boolean isCollectionRequired()- Specified by:
isCollectionRequired
in interfaceReferencePropertyInfo<NType,
NClass>
-
getSchemaType
- Specified by:
getSchemaType
in interfacePropertyInfo<NType,
NClass>
-
isRequired
public boolean isRequired()- Specified by:
isRequired
in interfaceReferencePropertyInfo<NType,
NClass>
-
collectElementNames
Description copied from class:CPropertyInfo
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.- Overrides:
collectElementNames
in classCPropertyInfo
- Returns:
- null if no conflict was found. Otherwise return the QName that has the collision.
-