throws Exception
{
// tests that by default the attributes used are
// named "plugin-class" and "plugin-id"
Digester digester = new Digester();
digester.setNamespaceAware( true );
PluginRules rc = new PluginRules();
digester.setRules( rc );
PluginDeclarationRule pdr = new PluginDeclarationRule();
digester.addRule( "root/plugin", pdr );
PluginCreateRule widgetPluginRule = new PluginCreateRule( Widget.class );
digester.addRule( "root/widget", widgetPluginRule );
digester.addSetNext( "root/widget", "addWidget" );
PluginCreateRule gadgetPluginRule = new PluginCreateRule( Widget.class );
digester.addRule( "root/gadget", gadgetPluginRule );
digester.addSetNext( "root/gadget", "addGadget" );
MultiContainer root = new MultiContainer();
digester.push( root );
try
{
digester.parse( Utils.getInputStream( this, "test7.xml" ) );
}
catch ( Exception e )
{
throw e;