org.jabber.jabberbeans.sax.Extension
Class DefaultExtension
java.lang.Object
|
+--org.jabber.jabberbeans.XMLData
|
+--org.jabber.jabberbeans.sax.Extension.DefaultExtension
- All Implemented Interfaces:
- Extension, MessageExtension, Packet, PresenceExtension, QueryExtension, java.io.Serializable
- public class DefaultExtension
- extends XMLData
- implements MessageExtension, QueryExtension, PresenceExtension, Packet
DefaultExtension
is a backend-specific handler for extensions
which are not known. Like all other Extension-derived objects, the one real
requirement is that it be able to render itself back as equivalent XML.
Note: It is recommended that this class not be programmed
directly for - it is backend specific, and could change substantially in
the future - plus a serialized representation does not result in
maintainable code
- See Also:
MessageExtension
,
QueryExtension
,
PresenceExtension
,
Serialized Form
Constructor Summary |
DefaultExtension(java.lang.String Element,
java.lang.String XMLNS,
java.lang.String XMLSnippet)
Creates a new DefaultExtension instance. |
Method Summary |
void |
appendItem(java.lang.StringBuffer retval)
Returns the XML representation for the data contained within. |
java.lang.String |
getXMLNamespace()
getXMLNamespace returns the XML namespace |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface org.jabber.jabberbeans.Packet |
toString |
DefaultExtension
public DefaultExtension(java.lang.String Element,
java.lang.String XMLNS,
java.lang.String XMLSnippet)
throws java.lang.InstantiationException
- Creates a new
DefaultExtension
instance.
- Parameters:
XMLNS
- the XML NamespaceXMLSnippet
- the full XML to be handled by the extension.
- Throws:
java.lang.InstantiationException
- if either parameter is not passed in
correctly
getXMLNamespace
public java.lang.String getXMLNamespace()
getXMLNamespace
returns the XML namespace
- Returns:
- a
String
holding the XML Namespace
appendItem
public void appendItem(java.lang.StringBuffer retval)
- Returns the XML representation for the data contained within.
- Specified by:
appendItem
in interface Extension
- Specified by:
appendItem
in class XMLData
- Parameters:
retval
- The StringBuffer
to append to
- Returns:
- a
String
in XML.