| java.lang.Object org.apache.commons.jxpath.JXPathContext org.apache.commons.jxpath.ri.JXPathContextReferenceImpl
JXPathContextReferenceImpl | public class JXPathContextReferenceImpl extends JXPathContext (Code) | | The reference implementation of JXPathContext.
author: Dmitri Plotnikov version: $Revision: 1.43 $ $Date: 2004/04/04 23:16:23 $ |
Method Summary | |
public static void | addNodePointerFactory(NodePointerFactory factory) Call this with a custom NodePointerFactory to add support for
additional types of objects. | public static Object | allocateConditionally(String className, String existenceCheckClassName) Checks if existenceCheckClass exists on the class path. | protected CompiledExpression | compilePath(String xpath) | public Pointer | createPath(String xpath) | public Pointer | createPath(String xpath, Expression expr) | public Pointer | createPathAndSetValue(String xpath, Object value) | public Pointer | createPathAndSetValue(String xpath, Expression expr, Object value) | public EvalContext | getAbsoluteRootContext() | protected Compiler | getCompiler() Returns a static instance of TreeCompiler. | public Pointer | getContextPointer() | public Function | getFunction(QName functionName, Object[] parameters) | public Pointer | getNamespaceContextPointer() | public NamespaceResolver | getNamespaceResolver() | public String | getNamespaceURI(String prefix) | public static NodePointerFactory[] | getNodePointerFactories() | public Pointer | getPointer(String xpath) | public Pointer | getPointer(String xpath, Expression expr) | public JXPathContext | getRelativeContext(Pointer pointer) | public Object | getValue(String xpath) Traverses the xpath and returns the resulting object. | public Object | getValue(String xpath, Expression expr) | public Object | getValue(String xpath, Class requiredType) Calls getValue(xpath), converts the result to the required type
and returns the result of the conversion. | public Object | getValue(String xpath, Expression expr, Class requiredType) | public NodePointer | getVariablePointer(QName name) | public Iterator | iterate(String xpath) Traverses the xpath and returns a Iterator of all results found
for the path. | public Iterator | iterate(String xpath, Expression expr) | public Iterator | iteratePointers(String xpath) Traverses the xpath and returns an Iterator of Pointers. | public Iterator | iteratePointers(String xpath, Expression expr) | public void | registerNamespace(String prefix, String namespaceURI) | public void | removeAll(String xpath) | public void | removeAll(String xpath, Expression expr) | public void | removePath(String xpath) | public void | removePath(String xpath, Expression expr) | public void | setNamespaceContextPointer(Pointer pointer) | public void | setValue(String xpath, Object value) | public void | setValue(String xpath, Expression expr, Object value) |
USE_SOFT_CACHE | final public static boolean USE_SOFT_CACHE(Code) | | Change this to false to disable soft caching of
CompiledExpressions.
|
addNodePointerFactory | public static void addNodePointerFactory(NodePointerFactory factory)(Code) | | Call this with a custom NodePointerFactory to add support for
additional types of objects. Make sure the factory returns
a name that puts it in the right position on the list of factories.
|
allocateConditionally | public static Object allocateConditionally(String className, String existenceCheckClassName)(Code) | | Checks if existenceCheckClass exists on the class path. If so, allocates
an instance of the specified class, otherwise returns null.
|
getCompiler | protected Compiler getCompiler()(Code) | | Returns a static instance of TreeCompiler.
Override this to return an aternate compiler.
|
getNamespaceContextPointer | public Pointer getNamespaceContextPointer()(Code) | | |
getValue | public Object getValue(String xpath)(Code) | | Traverses the xpath and returns the resulting object. Primitive
types are wrapped into objects.
|
getValue | public Object getValue(String xpath, Class requiredType)(Code) | | Calls getValue(xpath), converts the result to the required type
and returns the result of the conversion.
|
iterate | public Iterator iterate(String xpath)(Code) | | Traverses the xpath and returns a Iterator of all results found
for the path. If the xpath matches no properties
in the graph, the Iterator will not be null.
|
iteratePointers | public Iterator iteratePointers(String xpath)(Code) | | Traverses the xpath and returns an Iterator of Pointers.
A Pointer provides easy access to a property.
If the xpath matches no properties
in the graph, the Iterator be empty, but not null.
|
setNamespaceContextPointer | public void setNamespaceContextPointer(Pointer pointer)(Code) | | |
|
|