EAF 7.4 Util

org.enhydra.util.jivan
Class JivanSimpleXMLObjectImpl

java.lang.Object
  extended by org.enhydra.util.dom.SimpleXMLObjectImpl
      extended by org.enhydra.util.jivan.JivanSimpleXMLObjectImpl
All Implemented Interfaces:
org.enhydra.xml.io.DocumentInfo, org.enhydra.xml.xmlc.XMLObject, org.w3c.dom.Document, org.w3c.dom.Node

public class JivanSimpleXMLObjectImpl
extends SimpleXMLObjectImpl

Title: JivanSimpleXMLObjectImpl

Description: This class represents implementation of XMLObject interface. Its main purpose is to provide the way for creation of XMLObject object by passed Jivan org.w3c.dom.Document Jivan implementation. The XMLCObject created by this manner can be used in already existing writeDOM() methods of ServletHttpPresentationResponse object to perform http response. Note that this class was tested only in in http response, not in DOM manipulation, and some methods throw an exception because they are not implemented.

Copyright: Copyright (c) 2004

Company: Together

Version:
1.0
Author:
Vladimir Radisic

Field Summary
 
Fields inherited from interface org.enhydra.xml.xmlc.XMLObject
XMLC_GENERATED_CLASS_FIELD_NAME, XMLC_SOURCE_FILE_FIELD_NAME
 
Fields inherited from interface org.w3c.dom.Node
ATTRIBUTE_NODE, CDATA_SECTION_NODE, COMMENT_NODE, DOCUMENT_FRAGMENT_NODE, DOCUMENT_NODE, DOCUMENT_POSITION_CONTAINED_BY, DOCUMENT_POSITION_CONTAINS, DOCUMENT_POSITION_DISCONNECTED, DOCUMENT_POSITION_FOLLOWING, DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC, DOCUMENT_POSITION_PRECEDING, DOCUMENT_TYPE_NODE, ELEMENT_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, NOTATION_NODE, PROCESSING_INSTRUCTION_NODE, TEXT_NODE
 
Constructor Summary
JivanSimpleXMLObjectImpl()
           
 
Method Summary
 void setDocument(org.w3c.dom.Document document)
          Set the Jivan implemented DOM document associated with this object and optional encoding.
 void setDocument(org.jivan.html.document.DocumentManager docMan)
          Set the Jivan implemented DOM document associated with this object via corresponding DocumentManager and optional encoding.
 void setDocument(org.jivan.html.document.DocumentManager docMan, java.lang.String encoding)
          Set the Jivan implemented DOM document associated with this object via corresponding DocumentManager and optional encoding.
 void setDocument(org.jivan.html.document.DocumentManager docMan, java.lang.String mimeType, java.lang.String encoding)
          Set the Jivan implemented DOM document associated with this object via corresponding DocumentManager and optional encoding.
 void setDocument(org.w3c.dom.Document document, java.lang.String encoding)
          Set the Jivan implemented DOM document associated with this object and optional encoding.
 void setDocument(org.w3c.dom.Document document, java.lang.String mimeType, java.lang.String encoding)
          Set the Jivan implemented DOM document associated with this object and optional encoding.
 byte[] toByteDocument()
          Transforms Jivan Document DOM object to byte array.
 
Methods inherited from class org.enhydra.util.dom.SimpleXMLObjectImpl
adoptNode, appendChild, buildDocument, cloneDeepCheck, cloneNode, compareDocumentPosition, createAttribute, createAttributeNS, createCDATASection, createComment, createDocumentFragment, createElement, createElementNS, createEntityReference, createProcessingInstruction, createTextNode, doSetText, getAttributes, getBaseURI, getChildNodes, getDelegate, getDoctype, getDocument, getDocumentElement, getDocumentURI, getDomConfig, getDomFactory, getElementById, getElementsByTagName, getElementsByTagNameNS, getEncoding, getFeature, getFirstChild, getImplementation, getInputEncoding, getLastChild, getLocalName, getMIMEType, getNamespaceURI, getNextSibling, getNodeName, getNodeType, getNodeValue, getOwnerDocument, getParentNode, getPrefix, getPreviousSibling, getStandalone, getStrictErrorChecking, getTextContent, getUserData, getVersion, getXmlEncoding, getXmlStandalone, getXmlVersion, hasAttributes, hasChildNodes, importNode, initFields, insertBefore, isDefaultNamespace, isEqualNode, isSameNode, isSupported, isURLAttribute, lookupNamespaceURI, lookupPrefix, normalize, normalizeDocument, removeChild, renameNode, replaceChild, setDelegate, setDocumentURI, setEncoding, setNodeValue, setPrefix, setStandalone, setStrictErrorChecking, setTextContent, setUserData, setVersion, setXmlStandalone, setXmlVersion, syncAccessMethods, syncWithDocument, toDocument
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JivanSimpleXMLObjectImpl

public JivanSimpleXMLObjectImpl()
Method Detail

setDocument

public void setDocument(org.w3c.dom.Document document,
                        java.lang.String mimeType,
                        java.lang.String encoding)
Set the Jivan implemented DOM document associated with this object and optional encoding. Note that if argument 'document' is not of type org.jivan.html.dom.HTMLDocumentCEImpl, the ClassCastException will be thrown.

Overrides:
setDocument in class SimpleXMLObjectImpl
Parameters:
document - org.w3c.dom.Document implementation which should be associated with this object,
mimeType - The MIME type associated with the document.
encoding - The encoding associated with the document.

setDocument

public void setDocument(org.w3c.dom.Document document,
                        java.lang.String encoding)
Set the Jivan implemented DOM document associated with this object and optional encoding. The MIME type is set to default value ('text/html'). Note that if argument 'document' is not of type org.jivan.html.dom.HTMLDocumentCEImpl, the ClassCastException will be thrown.

Parameters:
document - org.w3c.dom.Document implementation which should be associated with this object,
encoding - The encoding associated with the document.

setDocument

public void setDocument(org.w3c.dom.Document document)
Set the Jivan implemented DOM document associated with this object and optional encoding. The MIME type is set to default value ('text/html'), and encoding is also set to default value ('UTF-8'). Note that if argument 'document' is not of type org.jivan.html.dom.HTMLDocumentCEImpl, the ClassCastException will be thrown.

Parameters:
document - org.w3c.dom.Document implementation which should be associated with this object,

setDocument

public void setDocument(org.jivan.html.document.DocumentManager docMan,
                        java.lang.String mimeType,
                        java.lang.String encoding)
Set the Jivan implemented DOM document associated with this object via corresponding DocumentManager and optional encoding.

Parameters:
docMan - appropriate DocumentManager object which contains the desired Jivan Document implementation (org.jivan.html.dom.HTMLDocumentCEImpl).
mimeType - The MIME type associated with the document.
encoding - The encoding associated with the document.

setDocument

public void setDocument(org.jivan.html.document.DocumentManager docMan,
                        java.lang.String encoding)
Set the Jivan implemented DOM document associated with this object via corresponding DocumentManager and optional encoding. The MIME type is set to default value ('text/html').

Parameters:
docMan - appropriate DocumentManager object which contains the desired Jivan Document implementation (org.jivan.html.dom.HTMLDocumentCEImpl).
encoding - The encoding associated with the document.

setDocument

public void setDocument(org.jivan.html.document.DocumentManager docMan)
Set the Jivan implemented DOM document associated with this object via corresponding DocumentManager and optional encoding. The MIME type is set to default value ('text/html'), and encoding is also set to default value ('UTF-8').

Parameters:
docMan - appropriate DocumentManager object which contains the desired Jivan Document implementation (org.jivan.html.dom.HTMLDocumentCEImpl).

toByteDocument

public byte[] toByteDocument()
                      throws java.io.IOException
Transforms Jivan Document DOM object to byte array. This will be done by using corresponding DocumentManager and its serialize() method

Returns:
DOM represented as byte array.
Throws:
java.io.IOException

EAF 7.4 Util