tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Christopher Piggott" <chr...@rochester.rr.com>
Subject RE: using digester from within a servlet
Date Mon, 24 Apr 2006 11:36:04 GMT
Frank W. Zammetti [mailto:fzlists@omnytex.com] writes ...
>It looks to me like your ObjectCreate rule is incorrect...
>I believe the class you reference must be the fully-qualified name.

That set me on the right track - thank you.  My ObjectCreate rule was actually OK because
I specified the Class itself, not the name of the class as a String:

	digester.addObjectCreate("config/xdb-config", XdbConfig.class);

The other problem is that I did not do this:

	digester.setUseContextClssLoader(true);

to tell Digester to use the right class loader.  Once Digester was able to find all of the
objects it had to create, it continued to blow up on my SetNext rules.  The reason here was
exactly what you said.  I was not specifying the fully-qualified name.  the addSetNext() I
am using looks like:

	digester.addSetNext(String, String, String) /* works only if class name is fully qualified
*/

I wouldn't have had this problem if there were one of these:

	digester.addSetNext(String, String, Class) /* does not exist */

so I might recommend adding that to Digester some time in the future.


Cool :-)

--Chris


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message