KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > objectweb > openccm > Containers > Plugins > EmptyConfiguration


1 /*====================================================================
2
3 OpenCCM: The Open CORBA Component Model Platform
4 Copyright (C) 2001-2002 USTL - LIFL - GOAL
5 Contact: openccm-team@objectweb.org
6
7 This library is free software; you can redistribute it and/or
8 modify it under the terms of the GNU Lesser General Public
9 License as published by the Free Software Foundation; either
10 version 2.1 of the License, or any later version.
11
12 This library is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 Lesser General Public License for more details.
16
17 You should have received a copy of the GNU Lesser General Public
18 License along with this library; if not, write to the Free Software
19 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
20 USA
21
22 Initial developer(s): Mathieu Vadet.
23 Contributor(s): ______________________________________.
24
25 ====================================================================*/

26
27 package org.objectweb.openccm.Containers.Plugins;
28
29 /**
30  * This interface ??????.
31  *
32  * @author <a HREF="mailto:Mathieu.Vadet@lifl.fr">Mathieu Vadet</a>
33  *
34  * @version 0.3
35  */

36
37 public class EmptyConfiguration
38        extends org.omg.CORBA.LocalObject JavaDoc
39        implements org.objectweb.openccm.Containers.SystemConfiguration
40 {
41     // ==================================================================
42
//
43
// Internal state.
44
//
45
// ==================================================================
46

47     // ==================================================================
48
//
49
// Constructor.
50
//
51
// ==================================================================
52

53     /**
54      ** The constructor.
55      **
56      **/

57     public
58     EmptyConfiguration()
59     {
60     }
61
62     // ==================================================================
63
//
64
// Internal methods.
65
//
66
// ==================================================================
67

68     // ==================================================================
69
//
70
// Public methods for the SystemConfiguration interface.
71
//
72
// ==================================================================
73

74     //
75
// IDL:goal.lifl.fr/OpenCCM/Containers/Container/SystemConfiguration/create_call_coordinator:1.0
76
//
77
/**
78      **
79      **/

80     public org.objectweb.openccm.Containers.CallCoordinator
81     create_call_coordinator(java.lang.String JavaDoc uid,
82                             java.lang.String JavaDoc op_name,
83                             org.objectweb.openccm.Containers.SystemHomeFinder finder)
84     {
85         try
86         {
87             org.objectweb.openccm.Containers.SystemHome home = null;
88             home = finder.find_system_home("EmptyCoordinatorHome");
89             return (org.objectweb.openccm.Containers.CallCoordinator)home.create_component(null);
90         }
91         catch(org.objectweb.openccm.Containers.HomeNotFound ex)
92         {
93             // Should never happen !!!
94
}
95         catch(org.objectweb.openccm.Containers.CreationFailed ex)
96         {
97             // Should never happen !!!
98
}
99         return null;
100     }
101
102     //
103
// IDL:goal.lifl.fr/OpenCCM/Containers/Container/SystemConfiguration/create_call_controllers:1.0
104
//
105
/**
106      **
107      **/

108     public org.objectweb.openccm.Containers.CallController[]
109     create_call_controllers(java.lang.String JavaDoc uid,
110                             java.lang.String JavaDoc op_name,
111                             org.objectweb.openccm.Containers.SystemHomeFinder finder)
112     {
113         try
114         {
115             org.objectweb.openccm.Containers.SystemHome home = null;
116             org.objectweb.openccm.Containers.CallController[] ctrls =
117                 new org.objectweb.openccm.Containers.CallController[1];
118             home = finder.find_system_home("EmptyControllerHome");
119             ctrls[0] = (org.objectweb.openccm.Containers.CallController)home.create_component(null);
120             return ctrls;
121         }
122         catch(org.objectweb.openccm.Containers.HomeNotFound ex)
123         {
124             // Should never happen !!!
125
}
126         catch(org.objectweb.openccm.Containers.CreationFailed ex)
127         {
128             // Should never happen !!!
129
}
130         return null;
131     }
132
133     //
134
// IDL:goal.lifl.fr/OpenCCM/Containers/Container/SystemConfiguration/create_activation_coordinator:1.0
135
//
136
/**
137      **
138      **/

139     public org.objectweb.openccm.Containers.ActivationCoordinator
140     create_activation_coordinator(java.lang.String JavaDoc uid,
141                                   org.objectweb.openccm.Containers.SystemHomeFinder finder)
142     {
143         // should never be called !!!
144
throw new java.lang.Error JavaDoc("Can\'t use an empty coordinator for activation");
145     }
146
147     //
148
// IDL:goal.lifl.fr/OpenCCM/Containers/Container/SystemConfiguration/create_activation_controllers:1.0
149
//
150
/**
151      **
152      **/

153     public org.objectweb.openccm.Containers.ActivationController[]
154     create_activation_controllers(java.lang.String JavaDoc uid,
155                                   org.objectweb.openccm.Containers.SystemHomeFinder finder)
156     {
157         // should never be called !!!
158
throw new java.lang.Error JavaDoc("Can\'t use an empty controller for activation");
159     }
160
161     //
162
// IDL:goal.lifl.fr/OpenCCM/Containers/Container/SystemConfiguration/create_PCAPolicies:1.0
163
//
164
/**
165      **
166      **/

167     public org.objectweb.openccm.Containers.PCAPolicy[]
168     create_PCAPolicies(java.lang.String JavaDoc uid,
169                        org.objectweb.openccm.Containers.SystemHomeFinder finder)
170     {
171         return new org.objectweb.openccm.Containers.PCAPolicy[0];
172     }
173
174     //
175
// IDL:goal.lifl.fr/OpenCCM/Containers/Container/SystemConfiguration/set_parent_configuration:1.0
176
//
177
/**
178      **
179      **/

180     public void
181     set_parent_configuration(org.objectweb.openccm.Containers.SystemConfiguration config)
182     {
183     }
184
185     // ==================================================================
186
//
187
// Public methods for the SystemComponent interface.
188
//
189
// ==================================================================
190

191     // ==================================================================
192
//
193
// Public methods for the Configuration interface.
194
//
195
// ==================================================================
196

197     //
198
// IDL:goal.lifl.fr/OpenCCM/Containers/Configuration/configure:1.0
199
//
200
/**
201      **
202      **/

203     public void
204     configure(org.objectweb.openccm.Containers.PropertySet config)
205     throws org.objectweb.openccm.Containers.ConfigurationFailed
206     {
207         //
208
// TODO : do nothing ???
209
//
210
throw new org.objectweb.openccm.Containers.ConfigurationFailed("not implemented !");
211     }
212 }
213
Popular Tags