org.apache.ws.jaxme.generator.sg
public interface TypeSG extends SGItem
Interface of a source generator for types; applies both to simple and complex types.
Method Summary | |
---|---|
void | generate() Generates the types sources. |
void | generate(JavaSource pSource) Generates the types sources as an inner class of the given. |
ComplexTypeSG | getComplexTypeSG() If the type is complex: Returns an instance of ComplexTypeSG generating the type. |
TypeSG | getExtendedType() If the type is an extension: Returns the extended type. |
XsQName | getName() If the type is global: Returns the types name. |
Object | getProperty(String pName) A property allows to store custom data related to the type. |
TypeSG | getRestrictedType() If the type is a restriction: Returns the restricted type. |
JavaQName | getRuntimeType() Returns the types runtime type. |
XsSchemaHeader | getSchemaHeader() Returns information on the types syntactical context. |
SimpleTypeSG | getSimpleTypeSG() If the type is simple: Returns an instance of SimpleTypeSG for generating the type. |
JavaField | getXMLField(JavaSource pSource, String pFieldName, String pDefaultValue) Generates a Java field for an instance of this type. |
JavaMethod | getXMLGetMethod(JavaSource pSource, String pFieldName, String pMethodName) Generates a get method returning an instance of this type. |
JavaMethod | getXMLIsSetMethod(JavaSource pSource, String pFieldName, String pMethodName) Generates an "isSet" method returning whether the field is set. |
JavaMethod | getXMLSetMethod(JavaSource pSource, String pFieldName, String pParamName, String pMethodName, boolean pSetIsSet) Generates a set method returning an instance of this type. |
boolean | isComplex() Returns whether the type is complex. |
boolean | isExtension() Returns whether the type is an extension of another type. |
boolean | isGlobalClass() Returns whether this type is generated with a global class. |
boolean | isGlobalType() Returns whether this is a global type. |
boolean | isRestriction() Returns whether the type is a restriction of another type. |
Object | newComplexTypeSG() If the type is complex: Creates an instance of org.apache.ws.jaxme.generator.sg.ComplexTypeSGChain generating the type. Implementation note: The type org.apache.ws.jaxme.generator.sg.ComplexTypeSGChain must not be exposed in the interface, because the interface class is used to generate this type. |
Object | newSimpleTypeSG() If the type is simple: Creates a new instance of org.apache.ws.jaxme.generator.sg.SimpleTypeSGChain generating the type. Implementation note: The type org.apache.ws.jaxme.generator.sg.SimpleTypeSGChain must not be exposed in the interface, because the interface class is used to generate this type. |
void | setProperty(String pName, Object pValue) A property allows to store custom data related to the type. |
Generates the types sources.
Generates the types sources as an inner class of the given.
If the type is complex: Returns an instance of ComplexTypeSG generating the type.
If the type is an extension: Returns the extended type.
Throws: IllegalStateException The type is no extension.
If the type is global: Returns the types name.
Throws: IllegalStateException The type isn't global.
A property allows to store custom data related to the type. Properties are used by external source generators. For example, the JDBC source generator will use this to store the complex types table name here.
If the type is a restriction: Returns the restricted type.
Throws: IllegalStateException The type is no restriction.
Returns the types runtime type.
Returns information on the types syntactical context.
If the type is simple: Returns an instance of SimpleTypeSG for generating the type.
Throws: IllegalStateException The type is complex.
Generates a Java field for an instance of this type.
Generates a get method returning an instance of this type.
Generates an "isSet" method returning whether the field is set.
Generates a set method returning an instance of this type.
Returns whether the type is complex. If so, it is valid to invoke the method TypeSG. Otherwise, you may invoke the method TypeSG.
Returns whether the type is an extension of another type.
Returns whether this type is generated with a global class.
Returns whether this is a global type.
Returns whether the type is a restriction of another type.
If the type is complex: Creates an instance of org.apache.ws.jaxme.generator.sg.ComplexTypeSGChain generating the type.
Implementation note: The type org.apache.ws.jaxme.generator.sg.ComplexTypeSGChain must not be exposed in the interface, because the interface class is used to generate this type. In other words, this interface must be compilable without the org.apache.ws.jaxme.generator.sg.ComplexTypeSGChain interface.
If the type is simple: Creates a new instance of org.apache.ws.jaxme.generator.sg.SimpleTypeSGChain generating the type.
Implementation note: The type org.apache.ws.jaxme.generator.sg.SimpleTypeSGChain must not be exposed in the interface, because the interface class is used to generate this type. In other words, this interface must be compilable without the org.apache.ws.jaxme.generator.sg.SimpleTypeSGChain interface.
A property allows to store custom data related to the type. Properties are used by external source generators. For example, the JDBC source generator will use this to store the complex types table name here.