|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.sun.tools.xjc.model.AbstractCTypeInfoImpl
abstract class AbstractCTypeInfoImpl
Partial implementation of CTypeInfo
.
The inheritance of TypeUse
by CTypeInfo
isn't a normal inheritance (see CTypeInfo
for more.)
This class implments methods on TypeUse
for CTypeInfo
.
Constructor Summary | |
---|---|
protected |
AbstractCTypeInfoImpl(Model model,
com.sun.xml.xsom.XSComponent source,
CCustomizations customizations)
|
Method Summary | |
---|---|
boolean |
canBeReferencedByIDREF()
Deprecated. why are you calling an unimplemented method? |
com.sun.codemodel.JExpression |
createConstant(Outline outline,
com.sun.xml.xsom.XmlString lexical)
Creates a constant for the given lexical value. |
CAdapter |
getAdapterUse()
If this type use is adapting the type, returns the adapter. |
CCustomizations |
getCustomizations()
Gets the list of customizations attached to this model component. |
javax.activation.MimeType |
getExpectedMimeType()
No default MimeType . |
CTypeInfo |
getInfo()
Individual item type. |
com.sun.xml.bind.v2.runtime.Location |
getLocation()
|
com.sun.xml.xsom.XSComponent |
getSchemaComponent()
If this model object is built from XML Schema, this property returns a schema component from which the model is built. |
com.sun.xml.bind.v2.model.annotation.Locatable |
getUpstream()
|
com.sun.xml.bind.v2.model.core.ID |
idUse()
Whether the referenced type (individual item type in case of collection) is ID/IDREF. |
boolean |
isCollection()
If the use can hold multiple values of the specified type. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface com.sun.tools.xjc.model.CTypeInfo |
---|
toType |
Methods inherited from interface com.sun.xml.bind.v2.model.core.TypeInfo |
---|
getType |
Methods inherited from interface com.sun.tools.xjc.model.CCustomizable |
---|
getLocator |
Constructor Detail |
---|
protected AbstractCTypeInfoImpl(Model model, com.sun.xml.xsom.XSComponent source, CCustomizations customizations)
Method Detail |
---|
public final boolean isCollection()
TypeUse
isCollection
in interface TypeUse
public final CAdapter getAdapterUse()
TypeUse
getAdapterUse
in interface TypeUse
public final CTypeInfo getInfo()
TypeUse
getInfo
in interface TypeUse
public final com.sun.xml.bind.v2.model.core.ID idUse()
TypeUse
ID is a property of a relationship. When a bean Foo has an ID property called 'bar' whose type is String, Foo isn't an ID, String isn't an ID, but this relationship is an ID (in the sense that Foo uses this String as an ID.)
The same thing can be said with IDREF. When Foo refers to Bar by means of IDREF, neither Foo nor Bar is IDREF.
That's why we have this method in TypeUse
.
idUse
in interface TypeUse
public final com.sun.xml.xsom.XSComponent getSchemaComponent()
CCustomizable
getSchemaComponent
in interface CCustomizable
public final boolean canBeReferencedByIDREF()
canBeReferencedByIDREF
in interface com.sun.xml.bind.v2.model.core.TypeInfo<NType,NClass>
public javax.activation.MimeType getExpectedMimeType()
MimeType
.
getExpectedMimeType
in interface TypeUse
public CCustomizations getCustomizations()
CCustomizable
getCustomizations
in interface CCustomizable
Plugin.getCustomizationURIs()
public com.sun.codemodel.JExpression createConstant(Outline outline, com.sun.xml.xsom.XmlString lexical)
TypeUse
For example, to create a constant 1 for xs:int, you'd do:
CBuiltinLeafInfo.INT.createConstant( codeModel, "1", null );
This method is invoked at the backend as a part of the code generation process.
createConstant
in interface TypeUse
TypeUse
(such as when it's a collection)public final com.sun.xml.bind.v2.model.annotation.Locatable getUpstream()
getUpstream
in interface com.sun.xml.bind.v2.model.annotation.Locatable
public final com.sun.xml.bind.v2.runtime.Location getLocation()
getLocation
in interface com.sun.xml.bind.v2.model.annotation.Locatable
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |