import org.springframework.beans.factory.BeanInitializationException;\r
import org.springframework.beans.factory.DisposableBean;\r
import org.springframework.beans.factory.FactoryBean;\r
-import org.springframework.beans.factory.InitializingBean;\r
import org.springframework.beans.factory.ListableBeanFactory;\r
import org.springframework.beans.factory.config.RuntimeBeanReference;\r
import org.springframework.util.ReflectionUtils;\r
/**\r
* A spring namespace handler to support plexus components creation and direct field-injection in a spring\r
* XmlApplicationContext.\r
- * \r
+ *\r
* @author <a href="mailto:nicolas@apache.org">Nicolas De Loof</a>\r
* @since 1.1\r
*/\r
builder.addPropertyValue( "role", element.getAttribute( "role" ) );\r
String implementation = element.getAttribute( "implementation" );\r
builder.addPropertyValue( "implementation", implementation );\r
+ builder.addPropertyValue( "instanciationStrategy", element.getAttribute( "instantiation-strategy" ) );\r
\r
Map dependencies = new HashMap();\r
\r
\r
<xsl:output method="xml"/>\r
\r
-<!-- \r
+<!--\r
Convert a plexus descriptor to a spring XML context with help of the custom <plexus: namespace\r
- to handle IoC containers incompatibilities. \r
+ to handle IoC containers incompatibilities.\r
-->\r
\r
<xsl:template match="/component-set">\r
<xsl:attribute name="implementation">\r
<xsl:value-of select="implementation" />\r
</xsl:attribute>\r
- <xsl:if test="instanciation-strategy">\r
- <xsl:attribute name="instanciation-strategy">\r
- <xsl:value-of select="instanciation-strategy" />\r
+ <xsl:if test="instantiation-strategy">\r
+ <xsl:attribute name="instantiation-strategy">\r
+ <xsl:value-of select="instantiation-strategy" />\r
</xsl:attribute>\r
</xsl:if>\r
<xsl:for-each select="requirements/requirement">\r
package org.codehaus.plexus.spring;\r
\r
import org.codehaus.plexus.logging.AbstractLogEnabled;\r
-import org.codehaus.plexus.logging.LogEnabled;\r
import org.codehaus.plexus.personality.plexus.lifecycle.phase.Disposable;\r
import org.codehaus.plexus.personality.plexus.lifecycle.phase.Initializable;\r
import org.codehaus.plexus.personality.plexus.lifecycle.phase.InitializationException;\r
-import org.codehaus.plexus.personality.plexus.lifecycle.phase.LogEnablePhase;\r
\r
/*\r
* Licensed to the Apache Software Foundation (ASF) under one\r
\r
/**\r
* A typical plexus component implementation\r
- * \r
+ *\r
* @author <a href="mailto:nicolas@apache.org">Nicolas De Loof</a>\r
*/\r
public class PlexusBeanImpl\r
implements PlexusBean, Initializable, Disposable\r
{\r
private String message;\r
- \r
+\r
private String state = "undefined";\r
\r
/**\r
\r
public void dispose()\r
{\r
- state = DISPOSED; \r
+ state = DISPOSED;\r
}\r
- \r
+\r
/**\r
* @see org.codehaus.plexus.spring.PlexusBean#toString()\r
*/\r