[jboss-user] [Javassist] - how to get ClassPool in EclipseApplication

Dennis Knotz do-not-reply at jboss.com
Mon Sep 19 09:21:45 EDT 2011

Dennis Knotz [http://community.jboss.org/people/sprigg] created the discussion

"how to get ClassPool in EclipseApplication"

To view the discussion, visit: http://community.jboss.org/message/627204#627204

I have a problem with getting the ClassPool in my EclipseApplication.

Here's the Use Case: I have an EclipseApplication where I can "run" my Interpreter for diagrams. To evaluate the guards i wanted to change an evaluation method, so i can use the whole java spectrum of conditions without writing my own Parser.

Now my problem: testing in an small java project worked perfectly, but integrating the "evaluation-classes" into my application won't work. Debugging says that the ClassPool.getDefault(); throws an Exception (unfortunately a non catchable).

And the question: what am i doing wron? is there any other way to get the ClassPool? Or is there any other way to manipulate classes without that pool? 

Here is the Code of my Evaluator ok, it's not a beauty ;-):

            ClassPool pool = ClassPool.getDefault();
        }catch(Exception e)

Reply to this message by going to Community

Start a new discussion in Javassist at Community

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20110919/4b40cc0e/attachment.html 

More information about the jboss-user mailing list