blob: 5f0551395344ad279ccc6680257c3ca31e10ac2c [file] [log] [blame]
Guillaume Nodet05fac962009-04-27 10:01:58 +00001<?xml version="1.0" encoding="UTF-8"?>
2<!--
3
4 Licensed to the Apache Software Foundation (ASF) under one or more
5 contributor license agreements. See the NOTICE file distributed with
6 this work for additional information regarding copyright ownership.
7 The ASF licenses this file to You under the Apache License, Version 2.0
8 (the "License"); you may not use this file except in compliance with
9 the License. You may obtain a copy of the License at
10
11 http://www.apache.org/licenses/LICENSE-2.0
12
13 Unless required by applicable law or agreed to in writing, software
14 distributed under the License is distributed on an "AS IS" BASIS,
15 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 See the License for the specific language governing permissions and
17 limitations under the License.
18
19-->
20<beans xmlns="http://www.springframework.org/schema/beans"
21 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
22 xmlns:osgi="http://www.springframework.org/schema/osgi"
23 xmlns:osgix="http://www.springframework.org/schema/osgi-compendium"
24 xmlns:util="http://www.springframework.org/schema/util"
25 xmlns:gshell="http://servicemix.apache.org/schema/servicemix-gshell"
26 xsi:schemaLocation="
27 http://www.springframework.org/schema/beans
28 http://www.springframework.org/schema/beans/spring-beans.xsd
29 http://www.springframework.org/schema/osgi
30 http://www.springframework.org/schema/osgi/spring-osgi.xsd
31 http://www.springframework.org/schema/osgi-compendium
32 http://www.springframework.org/schema/osgi-compendium/spring-osgi-compendium.xsd
33 http://www.springframework.org/schema/util
34 http://www.springframework.org/schema/util/spring-util.xsd
35 http://servicemix.apache.org/schema/servicemix-gshell
36 http://servicemix.apache.org/schema/servicemix-gshell/servicemix-gshell.xsd">
37
38 <import resource="classpath:org/apache/servicemix/kernel/gshell/core/commands.xml" />
39
40 <bean id="adminCommandBundleSupport" scope="prototype">
41 <property name="adminService" ref="adminService" />
42 </bean>
43
44 <gshell:command-bundle>
45 <gshell:command name="admin/create">
46 <gshell:action class="org.apache.servicemix.kernel.gshell.admin.internal.commands.CreateCommand"
47 parent="adminCommandBundleSupport" />
48 </gshell:command>
49 <gshell:command name="admin/connect">
50 <gshell:action class="org.apache.servicemix.kernel.gshell.admin.internal.commands.ConnectCommand"
51 parent="adminCommandBundleSupport" />
52 <gshell:completers>
53 <ref bean="instanceCompleter" />
54 <null/>
55 </gshell:completers>
56 </gshell:command>
57 <gshell:command name="admin/list">
58 <gshell:action class="org.apache.servicemix.kernel.gshell.admin.internal.commands.ListCommand"
59 parent="adminCommandBundleSupport" />
60 </gshell:command>
61 <gshell:command name="admin/start">
62 <gshell:action class="org.apache.servicemix.kernel.gshell.admin.internal.commands.StartCommand"
63 parent="adminCommandBundleSupport" />
64 <gshell:completers>
65 <ref bean="instanceCompleter" />
66 <null/>
67 </gshell:completers>
68 </gshell:command>
69 <gshell:command name="admin/stop">
70 <gshell:action class="org.apache.servicemix.kernel.gshell.admin.internal.commands.StopCommand"
71 parent="adminCommandBundleSupport" />
72 <gshell:completers>
73 <ref bean="instanceCompleter" />
74 <null/>
75 </gshell:completers>
76 </gshell:command>
77 <gshell:command name="admin/destroy">
78 <gshell:action class="org.apache.servicemix.kernel.gshell.admin.internal.commands.DestroyCommand"
79 parent="adminCommandBundleSupport" />
80 <gshell:completers>
81 <ref bean="instanceCompleter" />
82 <null/>
83 </gshell:completers>
84 </gshell:command>
85 <gshell:command name="admin/change-port">
86 <gshell:action class="org.apache.servicemix.kernel.gshell.admin.internal.commands.ChangePortCommand"
87 parent="adminCommandBundleSupport" />
88 <gshell:completers>
89 <ref bean="instanceCompleter" />
90 <null/>
91 </gshell:completers>
92 </gshell:command>
93 </gshell:command-bundle>
94
95 <osgi:reference id="preferences" interface="org.osgi.service.prefs.PreferencesService" cardinality="0..1" />
96
97 <bean id="adminService" class="org.apache.servicemix.kernel.gshell.admin.internal.AdminServiceImpl">
98 <property name="preferences" ref="preferences" />
99 </bean>
100
101 <bean id="instanceCompleter" class="org.apache.servicemix.kernel.gshell.admin.internal.completers.InstanceCompleter">
102 <property name="adminService" ref="adminService" />
103 </bean>
104
105
106</beans>