Class BaseXMLNode
java.lang.Object
com.webmethods.caf.faces.data.tree.object.BaseXMLNode
- All Implemented Interfaces:
IContentProvider
,INode
- Direct Known Subclasses:
XMLDOMNode2
,XMLElementNode2
Base class for adapting a W3C DOM
Node
to a CAF tree INode
and CAF data IContentProvider
(as a IContentProvider
,
binding-expression access to the node's properties can be optimized).-
Field Summary
FieldsModifier and TypeFieldDescriptionLazily created byINode.getChildren()
.protected String
Lazily created byINode.getId()
.protected INode
Null if root.protected org.apache.xpath.CachedXPathAPI
Lazily created bygetXPathAPI()
.Lazily created cache of xpaths to evaluated results. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetData()
Row data.Node parent, or null for root.Object[]
Returns list of properties supported by this content provider.Class<?>
Returns java type of the given propertyReturns value of the given propertyprotected abstract Node
Wrapped DOM node.protected org.apache.xpath.CachedXPathAPI
Xalan xpath api context.protected Object
getXPathValue
(String xpath) Evaluates the specified xpath for the wrapped dom node.boolean
hasProperty
(Object propertyKey) Checks if the given property is supported by this content providerMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.webmethods.caf.faces.data.IContentProvider
toString
Methods inherited from interface com.webmethods.caf.faces.data.tree.INode
getChildren, getId
-
Field Details
-
m_xpathAPI
protected org.apache.xpath.CachedXPathAPI m_xpathAPILazily created bygetXPathAPI()
. -
m_xpathCache
Lazily created cache of xpaths to evaluated results. -
m_id
Lazily created byINode.getId()
. -
m_parent
Null if root. -
m_children
Lazily created byINode.getChildren()
.
-
-
Constructor Details
-
BaseXMLNode
public BaseXMLNode()
-
-
Method Details
-
getData
Description copied from interface:INode
Row data. -
getParent
Description copied from interface:INode
Node parent, or null for root. -
getPropertyKeys
Description copied from interface:IContentProvider
Returns list of properties supported by this content provider. Can returnObject[0]
, never null.- Specified by:
getPropertyKeys
in interfaceIContentProvider
- Returns:
- array of property keys which is typically of type
String
orInteger
-
getType
Description copied from interface:IContentProvider
Returns java type of the given property- Specified by:
getType
in interfaceIContentProvider
- Parameters:
propertyKey
- the property key of typeString
orInteger
- Returns:
- property java
Class
- Throws:
PropertyNotFoundException
- if property is not supported
-
getValue
Description copied from interface:IContentProvider
Returns value of the given property- Specified by:
getValue
in interfaceIContentProvider
- Parameters:
propertyKey
- the property key of typeString
orInteger
- Returns:
- value of the property, can be
null
- Throws:
PropertyNotFoundException
- if property is not supportedELException
-
hasProperty
Description copied from interface:IContentProvider
Checks if the given property is supported by this content provider- Specified by:
hasProperty
in interfaceIContentProvider
- Parameters:
propertyKey
- property key of typeString
orInteger
- Returns:
true
if property is supported
-
getXMLNode
Wrapped DOM node. -
getXPathAPI
protected org.apache.xpath.CachedXPathAPI getXPathAPI()Xalan xpath api context. -
getXPathValue
Evaluates the specified xpath for the wrapped dom node.- Throws:
TransformerException
-