geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jdil...@apache.org
Subject svn commit: r698661 - in /geronimo/gshell/trunk: gshell-commands/gshell-admin/src/main/resources/META-INF/spring/ gshell-commands/gshell-bsf/src/main/resources/META-INF/spring/ gshell-commands/gshell-builtins/src/main/resources/META-INF/spring/ gshell-...
Date Wed, 24 Sep 2008 17:26:35 GMT
Author: jdillon
Date: Wed Sep 24 10:26:34 2008
New Revision: 698661

URL: http://svn.apache.org/viewvc?rev=698661&view=rev
Log:
Use the gshell namespace to simplify command plugin components.xml

Modified:
    geronimo/gshell/trunk/gshell-commands/gshell-admin/src/main/resources/META-INF/spring/components.xml
    geronimo/gshell/trunk/gshell-commands/gshell-bsf/src/main/resources/META-INF/spring/components.xml
    geronimo/gshell/trunk/gshell-commands/gshell-builtins/src/main/resources/META-INF/spring/components.xml
    geronimo/gshell/trunk/gshell-commands/gshell-optional/src/main/resources/META-INF/spring/components.xml
    geronimo/gshell/trunk/gshell-commands/gshell-repository/src/main/resources/META-INF/spring/components.xml
    geronimo/gshell/trunk/gshell-commands/gshell-vfs/src/main/resources/META-INF/spring/components.xml
    geronimo/gshell/trunk/gshell-wisdom/gshell-wisdom-core/src/main/java/org/apache/geronimo/gshell/wisdom/config/PluginParser.java

Modified: geronimo/gshell/trunk/gshell-commands/gshell-admin/src/main/resources/META-INF/spring/components.xml
URL: http://svn.apache.org/viewvc/geronimo/gshell/trunk/gshell-commands/gshell-admin/src/main/resources/META-INF/spring/components.xml?rev=698661&r1=698660&r2=698661&view=diff
==============================================================================
--- geronimo/gshell/trunk/gshell-commands/gshell-admin/src/main/resources/META-INF/spring/components.xml
(original)
+++ geronimo/gshell/trunk/gshell-commands/gshell-admin/src/main/resources/META-INF/spring/components.xml
Wed Sep 24 10:26:34 2008
@@ -23,42 +23,24 @@
 <beans xmlns="http://www.springframework.org/schema/beans"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xmlns:context="http://www.springframework.org/schema/context"
+       xmlns:gshell="http://gshell.org/schema/wisdom-gshell"
        xsi:schemaLocation="
             http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
-            http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd">
+            http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd
+            http://gshell.org/schema/wisdom-gshell http://gshell.org/schema/wisdom-gshell/wisdom-gshell.xsd">
 
     <context:annotation-config/>
 
-    <bean class="org.apache.geronimo.gshell.wisdom.plugin.PluginImpl">
-        <property name="id" value="gshell-admin"/>
-
-        <property name="activationRules">
-            <list>
-                <bean class="org.apache.geronimo.gshell.wisdom.plugin.activation.DefaultCommandBundleActivationRule">
-                    <property name="bundleId" value="default"/>
-                </bean>
-            </list>
-        </property>
-    </bean>
-
-    <bean name="gshell-admin:list-plugins" class="org.apache.geronimo.gshell.commands.admin.ListPluginsAction"
scope="prototype"/>
-
-    <bean name="gshell-admin:install-plugin" class="org.apache.geronimo.gshell.commands.admin.InstallPluginAction"
scope="prototype"/>
-
-    <bean class="org.apache.geronimo.gshell.wisdom.plugin.bundle.CommandBundle" lazy-init="true">
-        <property name="id" value="default"/>
-
-        <property name="commands">
-            <list>
-                <bean parent="statelessCommandTemplate">
-                    <property name="action" ref="gshell-admin:list-plugins"/>
-                </bean>
-
-                <bean parent="statefulCommandTemplate">
-                    <property name="actionId" value="gshell-admin:install-plugin"/>
-                </bean>
-            </list>
-        </property>
-    </bean>
+    <gshell:plugin name="gshell-admin">
+        <gshell:command-bundle name="default">
+            <gshell:command name="list-plugins" type="stateless">
+                <gshell:action class="org.apache.geronimo.gshell.commands.admin.ListPluginsAction"/>
+            </gshell:command>
+
+            <gshell:command name="install-plugin">
+                <gshell:action class="org.apache.geronimo.gshell.commands.admin.InstallPluginAction"/>
+            </gshell:command>
+        </gshell:command-bundle>
+    </gshell:plugin>
 
 </beans>
\ No newline at end of file

Modified: geronimo/gshell/trunk/gshell-commands/gshell-bsf/src/main/resources/META-INF/spring/components.xml
URL: http://svn.apache.org/viewvc/geronimo/gshell/trunk/gshell-commands/gshell-bsf/src/main/resources/META-INF/spring/components.xml?rev=698661&r1=698660&r2=698661&view=diff
==============================================================================
--- geronimo/gshell/trunk/gshell-commands/gshell-bsf/src/main/resources/META-INF/spring/components.xml
(original)
+++ geronimo/gshell/trunk/gshell-commands/gshell-bsf/src/main/resources/META-INF/spring/components.xml
Wed Sep 24 10:26:34 2008
@@ -23,36 +23,20 @@
 <beans xmlns="http://www.springframework.org/schema/beans"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xmlns:context="http://www.springframework.org/schema/context"
+       xmlns:gshell="http://gshell.org/schema/wisdom-gshell"
        xsi:schemaLocation="
             http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
-            http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd">
+            http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd
+            http://gshell.org/schema/wisdom-gshell http://gshell.org/schema/wisdom-gshell/wisdom-gshell.xsd">
 
     <context:annotation-config/>
 
-    <bean class="org.apache.geronimo.gshell.wisdom.plugin.PluginImpl">
-        <property name="id" value="gshell-bsf"/>
-
-        <property name="activationRules">
-            <list>
-                <bean class="org.apache.geronimo.gshell.wisdom.plugin.activation.DefaultCommandBundleActivationRule">
-                    <property name="bundleId" value="default"/>
-                </bean>
-            </list>
-        </property>
-    </bean>
-
-    <bean name="gshell-bsf:script" class="org.apache.geronimo.gshell.commands.bsf.ScriptAction"
scope="prototype"/>
-
-    <bean class="org.apache.geronimo.gshell.wisdom.plugin.bundle.CommandBundle" lazy-init="true">
-        <property name="id" value="default"/>
-
-        <property name="commands">
-            <list>
-                <bean parent="statefulCommandTemplate">
-                    <property name="actionId" value="gshell-bsf:script"/>
-                </bean>
-            </list>
-        </property>
-    </bean>
+    <gshell:plugin name="gshell-bsf">
+        <gshell:command-bundle name="default">
+            <gshell:command name="script">
+                <gshell:action class="org.apache.geronimo.gshell.commands.bsf.ScriptAction"/>
+            </gshell:command>
+        </gshell:command-bundle>
+    </gshell:plugin>
 
 </beans>
\ No newline at end of file

Modified: geronimo/gshell/trunk/gshell-commands/gshell-builtins/src/main/resources/META-INF/spring/components.xml
URL: http://svn.apache.org/viewvc/geronimo/gshell/trunk/gshell-commands/gshell-builtins/src/main/resources/META-INF/spring/components.xml?rev=698661&r1=698660&r2=698661&view=diff
==============================================================================
--- geronimo/gshell/trunk/gshell-commands/gshell-builtins/src/main/resources/META-INF/spring/components.xml
(original)
+++ geronimo/gshell/trunk/gshell-commands/gshell-builtins/src/main/resources/META-INF/spring/components.xml
Wed Sep 24 10:26:34 2008
@@ -23,99 +23,44 @@
 <beans xmlns="http://www.springframework.org/schema/beans"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xmlns:context="http://www.springframework.org/schema/context"
+       xmlns:gshell="http://gshell.org/schema/wisdom-gshell"
        xsi:schemaLocation="
             http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
-            http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd">
+            http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd
+            http://gshell.org/schema/wisdom-gshell http://gshell.org/schema/wisdom-gshell/wisdom-gshell.xsd">
 
     <context:annotation-config/>
 
-    <!--
     <gshell:plugin name="gshell-builtins">
         <gshell:command-bundle name="default">
-            <gshell:command name="help" type="stateful">
-                <gshell:action>
-                    <bean class="org.apache.geronimo.gshell.commands.builtins.HelpAction">
-                        // property|constructor|etc (normal stuff in beans ns
-                    </bean>
-                </gshell:action>
+            <gshell:command name="help">
+                <gshell:action class="org.apache.geronimo.gshell.commands.builtins.HelpAction"/>
             </gshell:command>
 
-            <gshell:command name="exit" action="org.apache.geronimo.gshell.commands.builtins.ExitAction"/>
// default type is stateful
+            <gshell:command name="exit">
+                <gshell:action class="org.apache.geronimo.gshell.commands.builtins.ExitAction"/>
+            </gshell:command>
+
+            <gshell:command name="echo">
+                <gshell:action class="org.apache.geronimo.gshell.commands.builtins.EchoAction"/>
+            </gshell:command>
 
             <gshell:command name="clear" type="stateless">
                 <gshell:action class="org.apache.geronimo.gshell.commands.builtins.ClearAction"/>
-                <gshell:completer class="org.apache.geronimo.gshell.commands.builtins.ClearCompleter"/>
             </gshell:command>
-        </gshell:command-bundle>
-
-        <gshell:activation>
-            <gshell:activation-rule class="org.apache.geronimo.gshell.wisdom.plugin.activation.DefaultCommandBundleActivationRule">
-                <property name="bundleId" value="default"/>
-            </gshell:activation-rule>
-        </gshell:activation>
-    </gshell:plugin>
-    -->
-
-    <bean class="org.apache.geronimo.gshell.wisdom.plugin.PluginImpl">
-        <property name="id" value="gshell-builtins"/>
-
-        <property name="activationRules">
-            <list>
-                <bean class="org.apache.geronimo.gshell.wisdom.plugin.activation.DefaultCommandBundleActivationRule">
-                    <property name="bundleId" value="default"/>
-                </bean>
-            </list>
-        </property>
-    </bean>
-
-    <bean name="gshell-builtins:help" class="org.apache.geronimo.gshell.commands.builtins.HelpAction"
scope="prototype"/>
-
-    <bean name="gshell-builtins:exit" class="org.apache.geronimo.gshell.commands.builtins.ExitAction"
scope="prototype"/>
-
-    <bean name="gshell-builtins:echo" class="org.apache.geronimo.gshell.commands.builtins.EchoAction"
scope="prototype"/>
-
-    <bean name="gshell-builtins:clear" class="org.apache.geronimo.gshell.commands.builtins.ClearAction"
scope="prototype"/>
-
-    <bean name="gshell-builtins:source" class="org.apache.geronimo.gshell.commands.builtins.SourceAction"
scope="prototype"/>
 
-    <bean name="gshell-builtins:set" class="org.apache.geronimo.gshell.commands.builtins.SetAction"
scope="prototype"/>
-
-    <bean name="gshell-builtins:unset" class="org.apache.geronimo.gshell.commands.builtins.UnsetAction"
scope="prototype"/>
-
-    <bean class="org.apache.geronimo.gshell.wisdom.plugin.bundle.CommandBundle" lazy-init="true">
-        <property name="id" value="default"/>
-
-        <property name="commands">
-            <list>
-                <bean parent="statelessCommandTemplate">
-                    <property name="action" ref="gshell-builtins:clear"/>
-                </bean>
-
-                <bean parent="statefulCommandTemplate">
-                    <property name="actionId" value="gshell-builtins:echo"/>
-                </bean>
-
-                <bean parent="statefulCommandTemplate">
-                    <property name="actionId" value="gshell-builtins:exit"/>
-                </bean>
-
-                <bean parent="statefulCommandTemplate">
-                    <property name="actionId" value="gshell-builtins:help"/>
-                </bean>
-
-                <bean parent="statefulCommandTemplate">
-                    <property name="actionId" value="gshell-builtins:source"/>
-                </bean>
+            <gshell:command name="source">
+                <gshell:action class="org.apache.geronimo.gshell.commands.builtins.SourceAction"/>
+            </gshell:command>
 
-                <bean parent="statefulCommandTemplate">
-                    <property name="actionId" value="gshell-builtins:set"/>
-                </bean>
+            <gshell:command name="set">
+                <gshell:action class="org.apache.geronimo.gshell.commands.builtins.SetAction"/>
+            </gshell:command>
 
-                <bean parent="statefulCommandTemplate">
-                    <property name="actionId" value="gshell-builtins:unset"/>
-                </bean>
-            </list>
-        </property>
-    </bean>
+            <gshell:command name="unset">
+                <gshell:action class="org.apache.geronimo.gshell.commands.builtins.UnsetAction"/>
+            </gshell:command>
+        </gshell:command-bundle>
+    </gshell:plugin>
 
 </beans>
\ No newline at end of file

Modified: geronimo/gshell/trunk/gshell-commands/gshell-optional/src/main/resources/META-INF/spring/components.xml
URL: http://svn.apache.org/viewvc/geronimo/gshell/trunk/gshell-commands/gshell-optional/src/main/resources/META-INF/spring/components.xml?rev=698661&r1=698660&r2=698661&view=diff
==============================================================================
--- geronimo/gshell/trunk/gshell-commands/gshell-optional/src/main/resources/META-INF/spring/components.xml
(original)
+++ geronimo/gshell/trunk/gshell-commands/gshell-optional/src/main/resources/META-INF/spring/components.xml
Wed Sep 24 10:26:34 2008
@@ -23,60 +23,36 @@
 <beans xmlns="http://www.springframework.org/schema/beans"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xmlns:context="http://www.springframework.org/schema/context"
+       xmlns:gshell="http://gshell.org/schema/wisdom-gshell"
        xsi:schemaLocation="
             http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
-            http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd">
+            http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd
+            http://gshell.org/schema/wisdom-gshell http://gshell.org/schema/wisdom-gshell/wisdom-gshell.xsd">
 
     <context:annotation-config/>
 
-    <bean class="org.apache.geronimo.gshell.wisdom.plugin.PluginImpl">
-        <property name="id" value="gshell-optional"/>
-
-        <property name="activationRules">
-            <list>
-                <bean class="org.apache.geronimo.gshell.wisdom.plugin.activation.DefaultCommandBundleActivationRule">
-                    <property name="bundleId" value="default"/>
-                </bean>
-            </list>
-        </property>
-    </bean>
-
-    <bean name="gshell-optional:cat" class="org.apache.geronimo.gshell.commands.optional.CatAction"
scope="prototype"/>
-
-    <bean name="gshell-optional:exec" class="org.apache.geronimo.gshell.commands.optional.ExecuteAction"
scope="prototype"/>
-
-    <bean name="gshell-optional:java" class="org.apache.geronimo.gshell.commands.optional.JavaAction"
scope="prototype"/>
-
-    <bean name="gshell-optional:sleep" class="org.apache.geronimo.gshell.commands.optional.SleepAction"
scope="prototype"/>
-
-    <bean name="gshell-optional:wait" class="org.apache.geronimo.gshell.commands.optional.WaitAction"
scope="prototype"/>
-
-    <bean class="org.apache.geronimo.gshell.wisdom.plugin.bundle.CommandBundle" lazy-init="true">
-        <property name="id" value="default"/>
-
-        <property name="commands">
-            <list>
-                <bean parent="statefulCommandTemplate">
-                    <property name="actionId" value="gshell-optional:cat"/>
-                </bean>
-
-                <bean parent="statefulCommandTemplate">
-                    <property name="actionId" value="gshell-optional:exec"/>
-                </bean>
-
-                <bean parent="statefulCommandTemplate">
-                    <property name="actionId" value="gshell-optional:java"/>
-                </bean>
-
-                <bean parent="statefulCommandTemplate">
-                    <property name="actionId" value="gshell-optional:sleep"/>
-                </bean>
-
-                <bean parent="statelessCommandTemplate">
-                    <property name="action" ref="gshell-optional:wait"/>
-                </bean>
-            </list>
-        </property>
-    </bean>
+    <gshell:plugin name="gshell-optional">
+        <gshell:command-bundle name="default">
+            <gshell:command name="cat">
+                <gshell:action class="org.apache.geronimo.gshell.commands.optional.CatAction"/>
+            </gshell:command>
+
+            <gshell:command name="exec">
+                <gshell:action class="org.apache.geronimo.gshell.commands.optional.ExecuteAction"/>
+            </gshell:command>
+
+            <gshell:command name="java">
+                <gshell:action class="org.apache.geronimo.gshell.commands.optional.JavaAction"/>
+            </gshell:command>
+
+            <gshell:command name="sleep">
+                <gshell:action class="org.apache.geronimo.gshell.commands.optional.SleepAction"/>
+            </gshell:command>
+
+            <gshell:command name="wait">
+                <gshell:action class="org.apache.geronimo.gshell.commands.optional.WaitAction"/>
+            </gshell:command>
+        </gshell:command-bundle>
+    </gshell:plugin>
 
 </beans>
\ No newline at end of file

Modified: geronimo/gshell/trunk/gshell-commands/gshell-repository/src/main/resources/META-INF/spring/components.xml
URL: http://svn.apache.org/viewvc/geronimo/gshell/trunk/gshell-commands/gshell-repository/src/main/resources/META-INF/spring/components.xml?rev=698661&r1=698660&r2=698661&view=diff
==============================================================================
--- geronimo/gshell/trunk/gshell-commands/gshell-repository/src/main/resources/META-INF/spring/components.xml
(original)
+++ geronimo/gshell/trunk/gshell-commands/gshell-repository/src/main/resources/META-INF/spring/components.xml
Wed Sep 24 10:26:34 2008
@@ -23,36 +23,20 @@
 <beans xmlns="http://www.springframework.org/schema/beans"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xmlns:context="http://www.springframework.org/schema/context"
+       xmlns:gshell="http://gshell.org/schema/wisdom-gshell"
        xsi:schemaLocation="
             http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
-            http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd">
+            http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd
+            http://gshell.org/schema/wisdom-gshell http://gshell.org/schema/wisdom-gshell/wisdom-gshell.xsd">
 
     <context:annotation-config/>
 
-    <bean class="org.apache.geronimo.gshell.wisdom.plugin.PluginImpl">
-        <property name="id" value="gshell-repository"/>
-
-        <property name="activationRules">
-            <list>
-                <bean class="org.apache.geronimo.gshell.wisdom.plugin.activation.DefaultCommandBundleActivationRule">
-                    <property name="bundleId" value="default"/>
-                </bean>
-            </list>
-        </property>
-    </bean>
-
-    <bean name="gshell-repository:resolve" class="org.apache.geronimo.gshell.commands.repository.ResolveAction"
scope="prototype"/>
-
-    <bean class="org.apache.geronimo.gshell.wisdom.plugin.bundle.CommandBundle" lazy-init="true">
-        <property name="id" value="default"/>
-
-        <property name="commands">
-            <list>
-                <bean parent="statefulCommandTemplate">
-                    <property name="actionId" value="gshell-repository:resolve"/>
-                </bean>
-            </list>
-        </property>
-    </bean>
+    <gshell:plugin name="gshell-repository">
+        <gshell:command-bundle name="default">
+            <gshell:command name="resolve">
+                <gshell:action class="org.apache.geronimo.gshell.commands.repository.ResolveAction"/>
+            </gshell:command>
+        </gshell:command-bundle>
+    </gshell:plugin>
 
 </beans>
\ No newline at end of file

Modified: geronimo/gshell/trunk/gshell-commands/gshell-vfs/src/main/resources/META-INF/spring/components.xml
URL: http://svn.apache.org/viewvc/geronimo/gshell/trunk/gshell-commands/gshell-vfs/src/main/resources/META-INF/spring/components.xml?rev=698661&r1=698660&r2=698661&view=diff
==============================================================================
--- geronimo/gshell/trunk/gshell-commands/gshell-vfs/src/main/resources/META-INF/spring/components.xml
(original)
+++ geronimo/gshell/trunk/gshell-commands/gshell-vfs/src/main/resources/META-INF/spring/components.xml
Wed Sep 24 10:26:34 2008
@@ -23,36 +23,20 @@
 <beans xmlns="http://www.springframework.org/schema/beans"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xmlns:context="http://www.springframework.org/schema/context"
+       xmlns:gshell="http://gshell.org/schema/wisdom-gshell"
        xsi:schemaLocation="
             http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
-            http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd">
+            http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd
+            http://gshell.org/schema/wisdom-gshell http://gshell.org/schema/wisdom-gshell/wisdom-gshell.xsd">
 
     <context:annotation-config/>
 
-    <bean class="org.apache.geronimo.gshell.wisdom.plugin.PluginImpl">
-        <property name="id" value="gshell-vfs"/>
-
-        <property name="activationRules">
-            <list>
-                <bean class="org.apache.geronimo.gshell.wisdom.plugin.activation.DefaultCommandBundleActivationRule">
-                    <property name="bundleId" value="default"/>
-                </bean>
-            </list>
-        </property>
-    </bean>
-
-    <bean name="gshell-vfs:copy" class="org.apache.geronimo.gshell.commands.vfs.CopyAction"
scope="prototype"/>
-
-    <bean class="org.apache.geronimo.gshell.wisdom.plugin.bundle.CommandBundle" lazy-init="true">
-        <property name="id" value="default"/>
-
-        <property name="commands">
-            <list>
-                <bean parent="statefulCommandTemplate">
-                    <property name="actionId" value="gshell-vfs:copy"/>
-                </bean>
-            </list>
-        </property>
-    </bean>
+    <gshell:plugin name="gshell-vfs">
+        <gshell:command-bundle name="default">
+            <gshell:command name="copy">
+                <gshell:action class="org.apache.geronimo.gshell.commands.vfs.CopyAction"/>
+            </gshell:command>
+        </gshell:command-bundle>
+    </gshell:plugin>
 
 </beans>
\ No newline at end of file

Modified: geronimo/gshell/trunk/gshell-wisdom/gshell-wisdom-core/src/main/java/org/apache/geronimo/gshell/wisdom/config/PluginParser.java
URL: http://svn.apache.org/viewvc/geronimo/gshell/trunk/gshell-wisdom/gshell-wisdom-core/src/main/java/org/apache/geronimo/gshell/wisdom/config/PluginParser.java?rev=698661&r1=698660&r2=698661&view=diff
==============================================================================
--- geronimo/gshell/trunk/gshell-wisdom/gshell-wisdom-core/src/main/java/org/apache/geronimo/gshell/wisdom/config/PluginParser.java
(original)
+++ geronimo/gshell/trunk/gshell-wisdom/gshell-wisdom-core/src/main/java/org/apache/geronimo/gshell/wisdom/config/PluginParser.java
Wed Sep 24 10:26:34 2008
@@ -20,6 +20,7 @@
 package org.apache.geronimo.gshell.wisdom.config;
 
 import org.apache.geronimo.gshell.wisdom.plugin.PluginImpl;
+import org.apache.geronimo.gshell.wisdom.plugin.activation.DefaultCommandBundleActivationRule;
 import org.apache.geronimo.gshell.wisdom.plugin.bundle.CommandBundle;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -187,6 +188,16 @@
                 // TODO: Handle registration of the bundles?
             }
 
+            //
+            // HACK: For now hard-code a single activation rule
+            //
+
+            BeanDefinitionBuilder rule = BeanDefinitionBuilder.rootBeanDefinition(DefaultCommandBundleActivationRule.class);
+            rule.addPropertyValue("bundleId", "default");
+            ManagedList rules = new ManagedList();
+            rules.add(rule.getBeanDefinition());
+            plugin.addPropertyValue("activationRules", rules);
+
             return plugin;
         }
 



Mime
View raw message