Vinay wrote:
Patch to
org.apache.avalon.assembly.engine.impl.DefaultTypeRepository
to enable verification of presence of lifecycle extension interface(s) declared within the extension
descriptor.
Vinay:
Can you re-send the patch as an attachement ?
Steve.
Regards, Vinay
=====================================================
64a65
importorg.apache.avalon.meta.info.ExtensionDescriptor;
194c195
< }
---
}198c199
< "Unexpected error while attempting to
build a type from the clas
sname: "
---
"Unexpected error while attempting tobuild a type from the clas
sname: "
378a380,381
//verify existence of lifecyle extensionclasses
Class[]lifecycleExtensions=getExtensionClasses(type);
403c406
< list.add( getServiceClass(
services[i] ) );
---
list.add( getServiceClass( service ));
455a459,496
/**classes provided by the given t
* Return the set of lifecycle extension
ype
* @param type the component typelifecycle extension inter
* @return an array of classes represnting the
faces provided by the type
*/)
private Class[] getExtensionClasses( Type type
{type.getExtensions();
ArrayList list = new ArrayList();
ExtensionDescriptor[] extensions =
for( int i = 0; i < extensions.length;i++ )
{= extensions[i];
ExtensionDescriptor extension
list.add( getExtensionClass(extension ) );
}Class[0] );
return (Class[]) list.toArray( new
}provided by the type.
/**
* Returns the lifecycle extension class
* @param extension the lifecycle extensiontype
* @return the class implementing theextension type
* @exception TypeRuntimeException if aclassloader error occurs
*/ExtensionDescriptor extension ) throws
private Class getExtensionClass(
TypeRuntimeException
{extension.getReference().getClassname()
final String classname =
;
trym_classloader.loadClass( classname );
{
return
} catch( Throwable e )load lifecycle extension clas
{
final String error =
"Could not
s of type: "
+ classname;TypeRuntimeException( error, e );
throw new
}
}
=====================================================
__________________________________ Do you Yahoo!? SBC Yahoo! DSL - Now only $29.95 per month! http://sbc.yahoo.com
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
--
Stephen J. McConnell mailto:[EMAIL PROTECTED] http://www.osm.net
Sent via James running under Merlin as an NT service. http://avalon.apache.org/sandbox/merlin
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
