com.manspace.resultSetDOMWrapper
Class ResultSetDocument

java.lang.Object
  |
  +--com.manspace.resultSetDOMWrapper.ReadOnlyNode
        |
        +--com.manspace.resultSetDOMWrapper.ReadOnlyElement
              |
              +--com.manspace.resultSetDOMWrapper.ArrayBasedElement
                    |
                    +--com.manspace.resultSetDOMWrapper.ResultSetDocument
All Implemented Interfaces:
org.w3c.dom.Document, org.w3c.dom.Element, org.w3c.dom.Node, org.w3c.dom.NodeList

public class ResultSetDocument
extends ArrayBasedElement
implements org.w3c.dom.Document

Implements a DOM view of a result-set

Version:
1.0
Author:
Tal Rotbart

Field Summary
protected static java.lang.String _propertyResultSet
          Static constant that holds the string identification for the result-set property; The constant is used to identify the properties in property / vetoable change events.
protected static java.lang.String _propertyResultSetDumbArray
          Static constant that holds the string identification for the result-set dumb-array property; The constant is used to identify the properties in property / vetoable change events.
protected static java.lang.String _propertyResultSetElement
          Static constant that holds the string identification for the result-set element property; The constant is used to identify the properties in property / vetoable change events.
static short NOT_IMPL_ERROR_CODE
          Constants
static java.lang.String NOT_IMPL_ERROR_MSG
           
 
Fields inherited from interface org.w3c.dom.Node
ATTRIBUTE_NODE, CDATA_SECTION_NODE, COMMENT_NODE, DOCUMENT_FRAGMENT_NODE, DOCUMENT_NODE, DOCUMENT_TYPE_NODE, ELEMENT_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, NOTATION_NODE, PROCESSING_INSTRUCTION_NODE, TEXT_NODE
 
Constructor Summary
ResultSetDocument(java.sql.ResultSet resultSet)
          Constructs a new result-set document
 
Method Summary
 void clear()
          Clear the elements array for GC
 org.w3c.dom.Attr createAttribute(java.lang.String name)
           
 org.w3c.dom.Attr createAttributeNS(java.lang.String namespaceURI, java.lang.String qualifiedName)
           
 org.w3c.dom.CDATASection createCDATASection(java.lang.String data)
           
 org.w3c.dom.Comment createComment(java.lang.String data)
           
 org.w3c.dom.DocumentFragment createDocumentFragment()
           
 org.w3c.dom.Element createElement(java.lang.String tagName)
           
 org.w3c.dom.Element createElementNS(java.lang.String namespaceURI, java.lang.String qualifiedName)
           
 org.w3c.dom.EntityReference createEntityReference(java.lang.String name)
           
 org.w3c.dom.ProcessingInstruction createProcessingInstruction(java.lang.String target, java.lang.String data)
           
 org.w3c.dom.Text createTextNode(java.lang.String data)
           
 org.w3c.dom.Element[] getChildElements()
          Returns the array of child elements
 java.lang.String getChildElementsLocalName()
          The local name of child elements
 org.w3c.dom.DocumentType getDoctype()
           
 org.w3c.dom.Element getDocumentElement()
           
 org.w3c.dom.Element getElementById(java.lang.String elementId)
           
 org.w3c.dom.DOMImplementation getImplementation()
           
 java.lang.String getLocalName()
           
 java.lang.String getNamespaceURI()
           
 org.w3c.dom.Node getNextSibling()
           
 short getNodeType()
           
 org.w3c.dom.Document getOwnerDocument()
           
 org.w3c.dom.Node getParentNode()
           
 java.lang.String getPrefix()
           
 org.w3c.dom.Node getPreviousSibling()
           
protected  java.sql.ResultSet getResultSet()
          Returns the result-set property
protected  ResultSetElement[] getResultSetDumbArray()
          Returns the result-set dumb-array property; If it doesn't exist -- creates it.
protected  ResultSetElement getResultSetElement()
          Returns the result-set element property; If it doesn't exist -- creates it.
 org.w3c.dom.Node importNode(org.w3c.dom.Node importedNode, boolean deep)
           
 
Methods inherited from class com.manspace.resultSetDOMWrapper.ArrayBasedElement
cloneNode, getAttribute, getAttributeNode, getAttributeNodeNS, getAttributeNS, getAttributes, getChildNodes, getElementsByTagName, getElementsByTagNameNS, getFirstChild, getLastChild, getLength, getNodeValue, hasAttribute, hasAttributeNS, hasAttributes, hasChildNodes, item
 
Methods inherited from class com.manspace.resultSetDOMWrapper.ReadOnlyElement
removeAttribute, removeAttributeNode, removeAttributeNS, setAttribute, setAttributeNode, setAttributeNodeNS, setAttributeNS
 
Methods inherited from class com.manspace.resultSetDOMWrapper.ReadOnlyNode
appendChild, getNodeName, getTagName, insertBefore, isSupported, normalize, removeChild, replaceChild, setNodeValue, setPrefix
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.w3c.dom.Document
getElementsByTagName, getElementsByTagNameNS
 
Methods inherited from interface org.w3c.dom.Node
appendChild, cloneNode, getAttributes, getChildNodes, getFirstChild, getLastChild, getNodeName, getNodeValue, hasAttributes, hasChildNodes, insertBefore, isSupported, normalize, removeChild, replaceChild, setNodeValue, setPrefix
 
Methods inherited from interface org.w3c.dom.Element
getTagName
 

Field Detail

_propertyResultSet

protected static final java.lang.String _propertyResultSet
Static constant that holds the string identification for the result-set property; The constant is used to identify the properties in property / vetoable change events.

See Also:
Constant Field Values

_propertyResultSetElement

protected static final java.lang.String _propertyResultSetElement
Static constant that holds the string identification for the result-set element property; The constant is used to identify the properties in property / vetoable change events.

See Also:
Constant Field Values

_propertyResultSetDumbArray

protected static final java.lang.String _propertyResultSetDumbArray
Static constant that holds the string identification for the result-set dumb-array property; The constant is used to identify the properties in property / vetoable change events.

See Also:
Constant Field Values

NOT_IMPL_ERROR_CODE

public static final short NOT_IMPL_ERROR_CODE
Constants

See Also:
Constant Field Values

NOT_IMPL_ERROR_MSG

public static final java.lang.String NOT_IMPL_ERROR_MSG
See Also:
Constant Field Values
Constructor Detail

ResultSetDocument

public ResultSetDocument(java.sql.ResultSet resultSet)
Constructs a new result-set document

Method Detail

getResultSet

protected java.sql.ResultSet getResultSet()
Returns the result-set property

Returns:
The result-set reference.

getResultSetElement

protected ResultSetElement getResultSetElement()
Returns the result-set element property; If it doesn't exist -- creates it.

Returns:
The result-set element reference.

getResultSetDumbArray

protected ResultSetElement[] getResultSetDumbArray()
Returns the result-set dumb-array property; If it doesn't exist -- creates it.

Returns:
The result-set dumb-array reference.

createAttribute

public org.w3c.dom.Attr createAttribute(java.lang.String name)
                                 throws org.w3c.dom.DOMException
Specified by:
createAttribute in interface org.w3c.dom.Document
org.w3c.dom.DOMException
See Also:
Document.createAttribute(java.lang.String)

createAttributeNS

public org.w3c.dom.Attr createAttributeNS(java.lang.String namespaceURI,
                                          java.lang.String qualifiedName)
                                   throws org.w3c.dom.DOMException
Specified by:
createAttributeNS in interface org.w3c.dom.Document
org.w3c.dom.DOMException
See Also:
Document.createAttributeNS(java.lang.String, java.lang.String)

createCDATASection

public org.w3c.dom.CDATASection createCDATASection(java.lang.String data)
                                            throws org.w3c.dom.DOMException
Specified by:
createCDATASection in interface org.w3c.dom.Document
org.w3c.dom.DOMException
See Also:
Document.createCDATASection(java.lang.String)

createComment

public org.w3c.dom.Comment createComment(java.lang.String data)
Specified by:
createComment in interface org.w3c.dom.Document
See Also:
Document.createComment(java.lang.String)

createDocumentFragment

public org.w3c.dom.DocumentFragment createDocumentFragment()
Specified by:
createDocumentFragment in interface org.w3c.dom.Document
See Also:
Document.createDocumentFragment()

createElement

public org.w3c.dom.Element createElement(java.lang.String tagName)
                                  throws org.w3c.dom.DOMException
Specified by:
createElement in interface org.w3c.dom.Document
org.w3c.dom.DOMException
See Also:
Document.createElement(java.lang.String)

createElementNS

public org.w3c.dom.Element createElementNS(java.lang.String namespaceURI,
                                           java.lang.String qualifiedName)
                                    throws org.w3c.dom.DOMException
Specified by:
createElementNS in interface org.w3c.dom.Document
org.w3c.dom.DOMException
See Also:
Document.createElementNS(java.lang.String, java.lang.String)

createEntityReference

public org.w3c.dom.EntityReference createEntityReference(java.lang.String name)
                                                  throws org.w3c.dom.DOMException
Specified by:
createEntityReference in interface org.w3c.dom.Document
org.w3c.dom.DOMException
See Also:
Document.createEntityReference(java.lang.String)

createProcessingInstruction

public org.w3c.dom.ProcessingInstruction createProcessingInstruction(java.lang.String target,
                                                                     java.lang.String data)
                                                              throws org.w3c.dom.DOMException
Specified by:
createProcessingInstruction in interface org.w3c.dom.Document
org.w3c.dom.DOMException
See Also:
Document.createProcessingInstruction(java.lang.String, java.lang.String)

createTextNode

public org.w3c.dom.Text createTextNode(java.lang.String data)
Specified by:
createTextNode in interface org.w3c.dom.Document
See Also:
Document.createTextNode(java.lang.String)

importNode

public org.w3c.dom.Node importNode(org.w3c.dom.Node importedNode,
                                   boolean deep)
                            throws org.w3c.dom.DOMException
Specified by:
importNode in interface org.w3c.dom.Document
org.w3c.dom.DOMException
See Also:
Document.importNode(org.w3c.dom.Node, boolean)

getDoctype

public org.w3c.dom.DocumentType getDoctype()
Specified by:
getDoctype in interface org.w3c.dom.Document
See Also:
Document.getDoctype()

getDocumentElement

public org.w3c.dom.Element getDocumentElement()
Specified by:
getDocumentElement in interface org.w3c.dom.Document
See Also:
Document.getDocumentElement()

getElementById

public org.w3c.dom.Element getElementById(java.lang.String elementId)
Specified by:
getElementById in interface org.w3c.dom.Document
See Also:
Document.getElementById(java.lang.String)

getImplementation

public org.w3c.dom.DOMImplementation getImplementation()
Specified by:
getImplementation in interface org.w3c.dom.Document
See Also:
Document.getImplementation()

getNodeType

public short getNodeType()
Specified by:
getNodeType in interface org.w3c.dom.Node
Overrides:
getNodeType in class ReadOnlyElement
See Also:
Node.getNodeType()

getLocalName

public java.lang.String getLocalName()
Specified by:
getLocalName in interface org.w3c.dom.Node
See Also:
Node.getLocalName()

getNamespaceURI

public java.lang.String getNamespaceURI()
Specified by:
getNamespaceURI in interface org.w3c.dom.Node
See Also:
Node.getNamespaceURI()

getNextSibling

public org.w3c.dom.Node getNextSibling()
Specified by:
getNextSibling in interface org.w3c.dom.Node
See Also:
Node.getNextSibling()

getOwnerDocument

public org.w3c.dom.Document getOwnerDocument()
Specified by:
getOwnerDocument in interface org.w3c.dom.Node
See Also:
Node.getOwnerDocument()

getParentNode

public org.w3c.dom.Node getParentNode()
Specified by:
getParentNode in interface org.w3c.dom.Node
See Also:
Node.getParentNode()

getPrefix

public java.lang.String getPrefix()
Specified by:
getPrefix in interface org.w3c.dom.Node
See Also:
Node.getPrefix()

getPreviousSibling

public org.w3c.dom.Node getPreviousSibling()
Specified by:
getPreviousSibling in interface org.w3c.dom.Node
See Also:
Node.getPreviousSibling()

getChildElements

public org.w3c.dom.Element[] getChildElements()
Description copied from class: ArrayBasedElement
Returns the array of child elements

Specified by:
getChildElements in class ArrayBasedElement
Returns:
The array of child elements
See Also:
com.mercury.topaz.tdm.adapters.dbAdapter.ArrayBasedElement#getChildElements()

getChildElementsLocalName

public java.lang.String getChildElementsLocalName()
Description copied from class: ArrayBasedElement
The local name of child elements

Specified by:
getChildElementsLocalName in class ArrayBasedElement
Returns:
The local name of child elements
See Also:
com.mercury.topaz.tdm.adapters.dbAdapter.ArrayBasedElement#getChildElementsLocalName()

clear

public void clear()
Description copied from class: ArrayBasedElement
Clear the elements array for GC

Specified by:
clear in class ArrayBasedElement
See Also:
com.manspace.resultSetDOMWrapper.ArrayBasedElement#clearElements()


Copyright © 2003 Tal Rotbart, Manspace. See LICENSE.TXT for license.