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,com.sun.xml.bind.v2.model.annotation.AnnotationSource,com.sun.xml.bind.v2.model.core.PropertyInfo<NType,NClass>,com.sun.xml.bind.v2.model.core.ReferencePropertyInfo<NType,NClass>
public final class CReferencePropertyInfo extends CPropertyInfo implements com.sun.xml.bind.v2.model.core.ReferencePropertyInfo<NType,NClass>
ReferencePropertyInfofor 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
Constructors Constructor Description CReferencePropertyInfo(String name, boolean collection, boolean required, boolean isMixed, XSComponent source, CCustomizations customizations, Locator locator, boolean dummy, boolean content, boolean isMixedExtended)
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description <V> Vaccept(CPropertyVisitor<V> visitor)<R,P>
Raccept(CPropertyVisitor2<R,P> visitor, P p)QNamecollectElementNames(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.CAdaptergetAdapter()NClassgetDOMHandler()Set<CElement>getElements()javax.activation.MimeTypegetExpectedMimeType()QNamegetSchemaType()com.sun.xml.bind.v2.model.core.WildcardModegetWildcard()QNamegetXmlName()Deprecated.com.sun.xml.bind.v2.model.core.IDid()A reference property can never be ID/IDREF because they always point to other element classes.booleanisCollectionNillable()booleanisCollectionRequired()booleanisContent()booleanisDummy()booleanisMixed()booleanisMixedExtendedCust()booleanisOptionalPrimitive()Returns true if this property needs to represent null just for the purpose of representing an absence of the property.booleanisRequired()booleanisUnboxable()Reference properties refer to elements, and none of the Java primitive type maps to an element.com.sun.xml.bind.v2.model.core.PropertyKindkind()Set<? extends CTypeInfo>ref()voidsetWildcard(com.sun.xml.bind.v2.model.core.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
-
-
-
-
Constructor Detail
-
CReferencePropertyInfo
public CReferencePropertyInfo(String name, boolean collection, boolean required, boolean isMixed, XSComponent source, CCustomizations customizations, Locator locator, boolean dummy, boolean content, boolean isMixedExtended)
-
-
Method Detail
-
isMixed
public boolean isMixed()
-
isDummy
public boolean isDummy()
-
isContent
public boolean isContent()
-
isMixedExtendedCust
public boolean isMixedExtendedCust()
-
getXmlName
@Deprecated public QName getXmlName()
Deprecated.We'll never use a wrapper element in XJC. Always return null.
-
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:
isUnboxablein classCPropertyInfo
-
isOptionalPrimitive
public boolean isOptionalPrimitive()
Description copied from class:CPropertyInfoReturns true if this property needs to represent null just for the purpose of representing an absence of the property.- Overrides:
isOptionalPrimitivein classCPropertyInfo
-
accept
public <V> V accept(CPropertyVisitor<V> visitor)
- Specified by:
acceptin classCPropertyInfo
-
accept
public <R,P> R accept(CPropertyVisitor2<R,P> visitor, P p)
- Specified by:
acceptin classCPropertyInfo
-
getAdapter
public CAdapter getAdapter()
- Specified by:
getAdapterin interfacecom.sun.xml.bind.v2.model.core.PropertyInfo<NType,NClass>- Specified by:
getAdapterin interfacecom.sun.xml.bind.v2.model.core.ReferencePropertyInfo<NType,NClass>- Specified by:
getAdapterin classCPropertyInfo
-
kind
public final com.sun.xml.bind.v2.model.core.PropertyKind kind()
-
id
public com.sun.xml.bind.v2.model.core.ID id()
A reference property can never be ID/IDREF because they always point to other element classes.
-
getWildcard
public com.sun.xml.bind.v2.model.core.WildcardMode getWildcard()
-
setWildcard
public void setWildcard(com.sun.xml.bind.v2.model.core.WildcardMode mode)
-
getDOMHandler
public NClass getDOMHandler()
-
getExpectedMimeType
public javax.activation.MimeType getExpectedMimeType()
-
isCollectionNillable
public boolean isCollectionNillable()
-
isCollectionRequired
public boolean isCollectionRequired()
-
getSchemaType
public QName getSchemaType()
-
isRequired
public boolean isRequired()
-
collectElementNames
public QName collectElementNames(Map<QName,CPropertyInfo> table)
Description copied from class:CPropertyInfoPuts 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:
collectElementNamesin classCPropertyInfo- Returns:
- null if no conflict was found. Otherwise return the QName that has the collision.
-
-