org.apache.ws.jaxme.generator.sg.impl
Class ComplexTypeSGImpl

java.lang.Object
  extended by org.apache.ws.jaxme.generator.sg.impl.ComplexTypeSGImpl
All Implemented Interfaces:
ComplexTypeSG

public class ComplexTypeSGImpl
extends java.lang.Object
implements ComplexTypeSG


Constructor Summary
ComplexTypeSGImpl(ComplexTypeSGChain o)
           
 
Method Summary
 void addAttributeSG(AttributeSG pAttribute)
          Adds the given AttributeSG to the list of attributes and invokes the method SGItem.init() on it.
 AttributeSG[] getAttributes()
          Returns the data types array of attributes.
 Context getClassContext()
          Returns the datatypes runtime type, which is the binding interface.
 ComplexContentSG getComplexContentSG()
          If the data type has complex content: Returns an instance of ComplexContentSG.
 ComplexTypeSGChain getHeadOfChain()
           
 org.xml.sax.Locator getLocator()
          Returns the types Locator.
 SimpleContentSG getSimpleContentSG()
          If the data type has simple content: Returns an instance of SimpleContentSG.
 TypeSG getTypeSG()
          Returns the TypeSG that created this instance.
 JavaSource getXMLHandler(JavaQName pQName)
          Generates the types XML handler as a standalone class.
 JavaSource getXMLHandler(JavaSource pSource)
          Generates the types XML handler as an inner class of the given.
 JavaSource getXMLImplementation()
          Generates the types implementation as a standalone class.
 JavaSource getXMLImplementation(JavaSource pSource)
          Generates the types implementation as an inner class of the given.
 JavaSource getXMLInterface()
          Generates the types interface as a standalone class.
 JavaSource getXMLInterface(JavaSource pSource)
          Generates the types interface as an inner class of the given.
 JavaSource getXMLSerializer()
          Generates the types XML serializer as a standalone class.
 JavaSource getXMLSerializer(JavaSource pSource)
          Generates the types XML serializer as an inner class of the given.
 boolean hasAttributes()
          Returns whether the data type has attributes.
 boolean hasSimpleContent()
          Returns whether the data type has simple content.
 void init()
          Initializes the instance.
 java.lang.Object newAttributeSG(XSAttribute pAttribute)
          Creates a new instance of AttributeSGChain generating the given attribute.
 java.lang.Object newAttributeSG(XSWildcard pWildcard)
          Creates a new instance of AttributeSGChain generating the given wildcard attributes.
 java.lang.Object newComplexContentTypeSG()
          If the complex type has complex content: Creates an instance of ComplexContentSGChain generating the given complex type.
 java.lang.Object newSimpleContentTypeSG()
          If the complex type has simple content: Creates an instance of SimpleContentSGChain generating the type.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ComplexTypeSGImpl

public ComplexTypeSGImpl(ComplexTypeSGChain o)
Method Detail

init

public void init()
          throws org.xml.sax.SAXException
Description copied from interface: ComplexTypeSG

Initializes the instance.

Specified by:
init in interface ComplexTypeSG
Throws:
org.xml.sax.SAXException

getTypeSG

public TypeSG getTypeSG()
Description copied from interface: ComplexTypeSG

Returns the TypeSG that created this instance.

Specified by:
getTypeSG in interface ComplexTypeSG

getLocator

public org.xml.sax.Locator getLocator()
Description copied from interface: ComplexTypeSG

Returns the types Locator.

Specified by:
getLocator in interface ComplexTypeSG

getClassContext

public Context getClassContext()
Description copied from interface: ComplexTypeSG

Returns the datatypes runtime type, which is the binding interface.

Specified by:
getClassContext in interface ComplexTypeSG

getXMLInterface

public JavaSource getXMLInterface()
                           throws org.xml.sax.SAXException
Description copied from interface: ComplexTypeSG

Generates the types interface as a standalone class. This is used for global types.

Specified by:
getXMLInterface in interface ComplexTypeSG
Throws:
org.xml.sax.SAXException

getXMLInterface

public JavaSource getXMLInterface(JavaSource pSource)
                           throws org.xml.sax.SAXException
Description copied from interface: ComplexTypeSG

Generates the types interface as an inner class of the given.

Specified by:
getXMLInterface in interface ComplexTypeSG
Throws:
org.xml.sax.SAXException

getXMLImplementation

public JavaSource getXMLImplementation()
                                throws org.xml.sax.SAXException
Description copied from interface: ComplexTypeSG

Generates the types implementation as a standalone class. This is used for global types.

Specified by:
getXMLImplementation in interface ComplexTypeSG
Throws:
org.xml.sax.SAXException

getXMLImplementation

public JavaSource getXMLImplementation(JavaSource pSource)
                                throws org.xml.sax.SAXException
Description copied from interface: ComplexTypeSG

Generates the types implementation as an inner class of the given.

Specified by:
getXMLImplementation in interface ComplexTypeSG
Throws:
org.xml.sax.SAXException

getXMLSerializer

public JavaSource getXMLSerializer()
                            throws org.xml.sax.SAXException
Description copied from interface: ComplexTypeSG

Generates the types XML serializer as a standalone class. This is used for global types.

Specified by:
getXMLSerializer in interface ComplexTypeSG
Throws:
org.xml.sax.SAXException

getXMLSerializer

public JavaSource getXMLSerializer(JavaSource pSource)
                            throws org.xml.sax.SAXException
Description copied from interface: ComplexTypeSG

Generates the types XML serializer as an inner class of the given. This is used for local types.

Specified by:
getXMLSerializer in interface ComplexTypeSG
Throws:
org.xml.sax.SAXException

getXMLHandler

public JavaSource getXMLHandler(JavaQName pQName)
                         throws org.xml.sax.SAXException
Description copied from interface: ComplexTypeSG

Generates the types XML handler as a standalone class. This is used for global types.

Specified by:
getXMLHandler in interface ComplexTypeSG
Throws:
org.xml.sax.SAXException

getXMLHandler

public JavaSource getXMLHandler(JavaSource pSource)
                         throws org.xml.sax.SAXException
Description copied from interface: ComplexTypeSG

Generates the types XML handler as an inner class of the given. This is used for local types.

Specified by:
getXMLHandler in interface ComplexTypeSG
Throws:
org.xml.sax.SAXException

hasAttributes

public boolean hasAttributes()
Description copied from interface: ComplexTypeSG

Returns whether the data type has attributes.

Specified by:
hasAttributes in interface ComplexTypeSG

newAttributeSG

public java.lang.Object newAttributeSG(XSAttribute pAttribute)
                                throws org.xml.sax.SAXException
Description copied from interface: ComplexTypeSG

Creates a new instance of AttributeSGChain generating the given attribute.

Specified by:
newAttributeSG in interface ComplexTypeSG
Throws:
org.xml.sax.SAXException

newAttributeSG

public java.lang.Object newAttributeSG(XSWildcard pWildcard)
                                throws org.xml.sax.SAXException
Description copied from interface: ComplexTypeSG

Creates a new instance of AttributeSGChain generating the given wildcard attributes.

Specified by:
newAttributeSG in interface ComplexTypeSG
Throws:
org.xml.sax.SAXException

addAttributeSG

public void addAttributeSG(AttributeSG pAttribute)
                    throws org.xml.sax.SAXException
Description copied from interface: ComplexTypeSG

Adds the given AttributeSG to the list of attributes and invokes the method SGItem.init() on it.

Specified by:
addAttributeSG in interface ComplexTypeSG
Throws:
org.xml.sax.SAXException

getAttributes

public AttributeSG[] getAttributes()
Description copied from interface: ComplexTypeSG

Returns the data types array of attributes.

Specified by:
getAttributes in interface ComplexTypeSG

hasSimpleContent

public boolean hasSimpleContent()
Description copied from interface: ComplexTypeSG

Returns whether the data type has simple content.

Specified by:
hasSimpleContent in interface ComplexTypeSG

newSimpleContentTypeSG

public java.lang.Object newSimpleContentTypeSG()
                                        throws org.xml.sax.SAXException
Description copied from interface: ComplexTypeSG

If the complex type has simple content: Creates an instance of SimpleContentSGChain generating the type.

Implementation note: The type SimpleContentSGChain 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 SimpleContentSGChain interface.

Specified by:
newSimpleContentTypeSG in interface ComplexTypeSG
Throws:
org.xml.sax.SAXException

getSimpleContentSG

public SimpleContentSG getSimpleContentSG()
Description copied from interface: ComplexTypeSG

If the data type has simple content: Returns an instance of SimpleContentSG. Uses ComplexTypeSG.newSimpleContentTypeSG() internally.

Specified by:
getSimpleContentSG in interface ComplexTypeSG

newComplexContentTypeSG

public java.lang.Object newComplexContentTypeSG()
                                         throws org.xml.sax.SAXException
Description copied from interface: ComplexTypeSG

If the complex type has complex content: Creates an instance of ComplexContentSGChain generating the given complex type.

Implementation note: The type ComplexContentSGChain 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 ComplexContentSGChain interface.

Specified by:
newComplexContentTypeSG in interface ComplexTypeSG
Throws:
org.xml.sax.SAXException

getComplexContentSG

public ComplexContentSG getComplexContentSG()
Description copied from interface: ComplexTypeSG

If the data type has complex content: Returns an instance of ComplexContentSG. Uses ComplexTypeSG.newComplexContentTypeSG() internally.

Specified by:
getComplexContentSG in interface ComplexTypeSG

getHeadOfChain

public ComplexTypeSGChain getHeadOfChain()