java - How to traverse XPath recursively? -


Is there a way to recurs an XPath query (and if so, how?)

< P> I have AST in Java with the following scenario

  @ relevant public zero foo () {time (true); } Public Zero Bar (Boolean Flag) {Shock Thrust; }  

I want to find the method that has been annotated with 'relevant' (this easy) and check whether the method is called in foo (here bar), its Details have been emphasized.

a) How do I remove the name 'bar' and ask XPath for a method called 'bar'?

And if 'bar' actually calls 'bla'

Hope it makes sense ...

For any help Thank you

There is not enough expense for one task that you are trying to complete.

First of all, you need a type of binding (for the time () method declaration, for example).

Secondly, you have to develop some type of static code analyzer, which runs continuously on AST and tries to fulfill a condition that "an expression expression exists" in the call stack.

You can take a look at Eclipse JDT source code how the binding applies Once you are bound, you can add your logic to it.


Comments

Popular posts from this blog

MySql variables and php -

url rewriting - How to implement the returnurl like SO in PHP? -

Which Python client library should I use for CouchdB? -