commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kees Jongenburger <>
Subject [jxpath] howto optimize
Date Sun, 20 Jun 2004 20:56:52 GMT

I am in  the process of learing jxpath and I wonder if it is possible to  
optimize results.
(I am programming against the mmbase bridge)

and have this jxpah query

JXPathContext context = JXPathContext.newContext(cloud);
NodeManager nodeManager = (NodeManager) context.getValue("nodeManagers[name = 
'news' ]/.");
This of course gets all "nodeManagers" and iterates though the result. Now the 
Cloud interface also has a method getNodeManager(String name);
that I called via jxpath
JXPathContext context = JXPathContext.newContext(cloud);
context.getVariables().declareVariable("cloud", cloud);
NodeManager nodeManager 

This of course looks to much like java code:)

can sombody tell me is it's possible  for jxpath to delegate some "constraints 
(like name = "news") to an other class?

my second question:
is there a way I can disable the jxpath feature that enables it to call static 
methods? I would like to use jxpah to provice access to mmbase from a remote 
location but 
JXPathContext context = JXPathContext.newContext(new String());

scares me :)

greeting and (for me sleepless nights).

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message