[jdom-interest] IllegalAccessError : how to pass Element to constructor

GB/DEV - Philip Nelson philip.nelson at omniresources.com
Wed Feb 28 05:48:07 PST 2001


> 30 minutes seems like an eternity, when one is stuck on a difficult
> problem, like this.  I hope that this may change.

It does seem to vary.

> The code, in which the constructors, are located ,is:
<snip>
>     Document doc = builder.build(w3cdoc);
>     Element rootElmt = doc.getRootElement();
>     List processList = rootElmt.getChildren();
>     Iterator i = processList.iterator();
>     System.out.println("here");
>     while(i.hasNext()) {
>       Object o = i.next();
>       Interactor iactor = new Interactor((Element) o);
>     }
>     System.out.println("there");
>   }

Your code runs just fine.  You do make the assumption that there are only
elements under the root node and that could cause you a problem with casting
at some point.  As for your problem, I think the comment someone made about
Debian is worth looking into.  If you are really running a shell script when
you type java, you could have all sorts of interesting things happening.  It
would explain what's going on.  Does Debian linux have whence?

Good luck!



More information about the jdom-interest mailing list