commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Simon Kitching <si...@ecnetwork.co.nz>
Subject Re: [Digester] addSetProperties
Date Fri, 19 Mar 2004 08:02:01 GMT
On Fri, 2004-03-19 at 07:32, Pretterhofer, Guenter (ext.) wrote:
> <property>
> 	<database name="db1">
> 		<user>user1</user>
> 	</database>
> 	<database name="db2">
> 		<user>user2</user>
> 	</database>
> </property>
[snip]
> 			digester.addObjectCreate("property",
> Property.class);
> 
> 			digester.addObjectCreate("property/database",
> Database.class);
> 			
> 			digester.addSetNext("property/database",
> "addDatabase");
> 			
> 			digester.addSetProperties("/property/database");
> 	
> digester.addBeanPropertySetter("property/database/user", "user");

All looks ok to me, except that the pattern "/property/database" should
be "property/database". With the leading slash, it is probably getting
completely ignored.

Are you aware that Digester generates lots of useful debug output if you
enable logging? Digester uses "commons-logging", so you just need to set
the right properties via "java -Dxxxxx" or have the right logging config
files in the classpath to enable logging. See the docs for
commons-logging for more info.

Regards,

Simon


---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org


Mime
View raw message