Hi Paul, one of the things I have learned, when dealing with Cocoon was, never to trust the actual error message ... or, when thinking about try-catch blocks inside finally blocks in my Java Flow, not even to try to understand them ;-)
I would guess your original code was fine. I would tip on the PasswordEncoder class not being there anymore or it having a changed signature. Have you checked your classpath manually that it is really there? I would never depend on code in the demo and samples parts of Cocoon, as I would think they change much too often ... as they are just used for demonstration purposes. Chris -----Ursprüngliche Nachricht----- Von: Paul Joseph [mailto:[email protected]] Gesendet: Dienstag, 24. Februar 2009 01:16 An: [email protected] Betreff: Re: problem with this line? I guess the message (below) was telling me that I had a Package, not a class. org.mozilla.javascript.EvaluatorException: "file:///C:/Program Files/Apache Software Foundation/Tomcat 5.5/webapps/webapp/webtask/request/Request.js", line 8: Not a Java class: [JavaPackage org.apache.cocoon.ojb.samples.bean.PasswordEncoder] I changed the line by taking out the "new" at the beginning and the () at the end to: var encoder = Packages.org.apache.cocoon.ojb.samples.bean.PasswordEncoder; And lo and behold it works. Not sure why as in my PasswordEncoder.java file, PasswordEncoder is a class. public class PasswordEncoder { ... } Paul Benjamin Boksa wrote: >> Any ideas anyone? > > Have you tried > > importClass(Packages.rg.apache.cocoon.ojb.samples.bean.PasswordEncoder); > > [...] > > var encoder = new PasswordEncoder(); > > ? > > Just an "any idea" ;-). I have not tried it - but I use the construct > above in some places. > > Let me know if that helps > > Benjamin > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
