KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > omg > mof > Model > ConstraintClassPOA


1 package org.omg.mof.Model;
2
3
4 /**
5 * org/omg/mof/Model/ConstraintClassPOA.java .
6 * Generated by the IDL-to-Java compiler (portable), version "3.1"
7 * from mof1.idl
8 * lundi 17 mars 2003 15 h 01 CET
9 */

10
11
12 //
13
public abstract class ConstraintClassPOA extends org.omg.PortableServer.Servant JavaDoc
14  implements org.omg.mof.Model.ConstraintClassOperations, org.omg.CORBA.portable.InvokeHandler JavaDoc
15 {
16
17   // Constructors
18

19   private static java.util.Hashtable JavaDoc _methods = new java.util.Hashtable JavaDoc ();
20   static
21   {
22     _methods.put ("_get_all_of_type_constraint", new java.lang.Integer JavaDoc (0));
23     _methods.put ("_get_all_of_class_constraint", new java.lang.Integer JavaDoc (1));
24     _methods.put ("create_constraint", new java.lang.Integer JavaDoc (2));
25     _methods.put ("_get_all_of_type_model_element", new java.lang.Integer JavaDoc (3));
26     _methods.put ("ref_is_instance_of", new java.lang.Integer JavaDoc (4));
27     _methods.put ("ref_create_instance", new java.lang.Integer JavaDoc (5));
28     _methods.put ("ref_all_objects", new java.lang.Integer JavaDoc (6));
29     _methods.put ("ref_set_value", new java.lang.Integer JavaDoc (7));
30     _methods.put ("ref_value", new java.lang.Integer JavaDoc (8));
31     _methods.put ("ref_unset_value", new java.lang.Integer JavaDoc (9));
32     _methods.put ("ref_add_value", new java.lang.Integer JavaDoc (10));
33     _methods.put ("ref_add_value_before", new java.lang.Integer JavaDoc (11));
34     _methods.put ("ref_add_value_at", new java.lang.Integer JavaDoc (12));
35     _methods.put ("ref_modify_value", new java.lang.Integer JavaDoc (13));
36     _methods.put ("ref_modify_value_at", new java.lang.Integer JavaDoc (14));
37     _methods.put ("ref_remove_value", new java.lang.Integer JavaDoc (15));
38     _methods.put ("ref_remove_value_at", new java.lang.Integer JavaDoc (16));
39     _methods.put ("ref_immediate_composite", new java.lang.Integer JavaDoc (17));
40     _methods.put ("ref_outermost_composite", new java.lang.Integer JavaDoc (18));
41     _methods.put ("ref_invoke_operation", new java.lang.Integer JavaDoc (19));
42     _methods.put ("ref_mof_id", new java.lang.Integer JavaDoc (20));
43     _methods.put ("ref_meta_object", new java.lang.Integer JavaDoc (21));
44     _methods.put ("ref_itself", new java.lang.Integer JavaDoc (22));
45     _methods.put ("ref_immediate_package", new java.lang.Integer JavaDoc (23));
46     _methods.put ("ref_outermost_package", new java.lang.Integer JavaDoc (24));
47     _methods.put ("ref_delete", new java.lang.Integer JavaDoc (25));
48   }
49
50   public org.omg.CORBA.portable.OutputStream JavaDoc _invoke (String JavaDoc $method,
51                                 org.omg.CORBA.portable.InputStream JavaDoc in,
52                                 org.omg.CORBA.portable.ResponseHandler JavaDoc $rh)
53   {
54     org.omg.CORBA.portable.OutputStream JavaDoc out = null;
55     java.lang.Integer JavaDoc __method = (java.lang.Integer JavaDoc)_methods.get ($method);
56     if (__method == null)
57       throw new org.omg.CORBA.BAD_OPERATION JavaDoc (0, org.omg.CORBA.CompletionStatus.COMPLETED_MAYBE);
58
59     switch (__method.intValue ())
60     {
61        case 0: // org/omg/mof/Model/ConstraintClass/_get_all_of_type_constraint
62
{
63          org.omg.mof.Model.Constraint $result[] = null;
64          $result = this.all_of_type_constraint ();
65          out = $rh.createReply();
66          org.omg.mof.Model.ConstraintSetHelper.write (out, $result);
67          break;
68        }
69
70        case 1: // org/omg/mof/Model/ConstraintClass/_get_all_of_class_constraint
71
{
72          org.omg.mof.Model.Constraint $result[] = null;
73          $result = this.all_of_class_constraint ();
74          out = $rh.createReply();
75          org.omg.mof.Model.ConstraintSetHelper.write (out, $result);
76          break;
77        }
78
79        case 2: // org/omg/mof/Model/ConstraintClass/create_constraint
80
{
81          try {
82            String JavaDoc name = in.read_string ();
83            String JavaDoc annotation = in.read_string ();
84            org.omg.mof.Model.ConstraintClassPackage.EvaluationKind evaluation_policy = org.omg.mof.Model.ConstraintClassPackage.EvaluationKindHelper.read (in);
85            org.omg.CORBA.Any JavaDoc expression = in.read_any ();
86            String JavaDoc language = in.read_string ();
87            org.omg.mof.Model.Constraint $result = null;
88            $result = this.create_constraint (name, annotation, evaluation_policy, expression, language);
89            out = $rh.createReply();
90            org.omg.mof.Model.ConstraintHelper.write (out, $result);
91          } catch (org.omg.mof.Reflective.MofError $ex) {
92            out = $rh.createExceptionReply ();
93            org.omg.mof.Reflective.MofErrorHelper.write (out, $ex);
94          }
95          break;
96        }
97
98        case 3: // org/omg/mof/Model/ModelElementClass/_get_all_of_type_model_element
99
{
100          org.omg.mof.Model.ModelElement $result[] = null;
101          $result = this.all_of_type_model_element ();
102          out = $rh.createReply();
103          org.omg.mof.Model.ModelElementSetHelper.write (out, $result);
104          break;
105        }
106
107        case 4: // org/omg/mof/Reflective/RefObject/ref_is_instance_of
108
{
109          org.omg.mof.Reflective.RefObject some_class = org.omg.mof.Reflective.DesignatorTypeHelper.read (in);
110          boolean consider_subtypes = in.read_boolean ();
111          boolean $result = false;
112          $result = this.ref_is_instance_of (some_class, consider_subtypes);
113          out = $rh.createReply();
114          out.write_boolean ($result);
115          break;
116        }
117
118        case 5: // org/omg/mof/Reflective/RefObject/ref_create_instance
119
{
120          try {
121            org.omg.CORBA.Any JavaDoc args[] = org.omg.mof.Reflective.ValueTypeListHelper.read (in);
122            org.omg.mof.Reflective.RefObject $result = null;
123            $result = this.ref_create_instance (args);
124            out = $rh.createReply();
125            org.omg.mof.Reflective.RefObjectHelper.write (out, $result);
126          } catch (org.omg.mof.Reflective.MofError $ex) {
127            out = $rh.createExceptionReply ();
128            org.omg.mof.Reflective.MofErrorHelper.write (out, $ex);
129          }
130          break;
131        }
132
133        case 6: // org/omg/mof/Reflective/RefObject/ref_all_objects
134
{
135          boolean include_subtypes = in.read_boolean ();
136          org.omg.mof.Reflective.RefObject $result[] = null;
137          $result = this.ref_all_objects (include_subtypes);
138          out = $rh.createReply();
139          org.omg.mof.Reflective.RefObjectSetHelper.write (out, $result);
140          break;
141        }
142
143        case 7: // org/omg/mof/Reflective/RefObject/ref_set_value
144
{
145          try {
146            org.omg.mof.Reflective.RefObject feature = org.omg.mof.Reflective.DesignatorTypeHelper.read (in);
147            org.omg.CORBA.Any JavaDoc new_value = org.omg.mof.Reflective._ValueTypeHelper.read (in);
148            this.ref_set_value (feature, new_value);
149            out = $rh.createReply();
150          } catch (org.omg.mof.Reflective.MofError $ex) {
151            out = $rh.createExceptionReply ();
152            org.omg.mof.Reflective.MofErrorHelper.write (out, $ex);
153          }
154          break;
155        }
156
157        case 8: // org/omg/mof/Reflective/RefObject/ref_value
158
{
159          try {
160            org.omg.mof.Reflective.RefObject feature = org.omg.mof.Reflective.DesignatorTypeHelper.read (in);
161            org.omg.CORBA.Any JavaDoc $result = null;
162            $result = this.ref_value (feature);
163            out = $rh.createReply();
164            out.write_any ($result);
165          } catch (org.omg.mof.Reflective.NotSet $ex) {
166            out = $rh.createExceptionReply ();
167            org.omg.mof.Reflective.NotSetHelper.write (out, $ex);
168          } catch (org.omg.mof.Reflective.MofError $ex) {
169            out = $rh.createExceptionReply ();
170            org.omg.mof.Reflective.MofErrorHelper.write (out, $ex);
171          }
172          break;
173        }
174
175        case 9: // org/omg/mof/Reflective/RefObject/ref_unset_value
176
{
177          try {
178            this.ref_unset_value ();
179            out = $rh.createReply();
180          } catch (org.omg.mof.Reflective.MofError $ex) {
181            out = $rh.createExceptionReply ();
182            org.omg.mof.Reflective.MofErrorHelper.write (out, $ex);
183          }
184          break;
185        }
186
187        case 10: // org/omg/mof/Reflective/RefObject/ref_add_value
188
{
189          try {
190            org.omg.mof.Reflective.RefObject feature = org.omg.mof.Reflective.DesignatorTypeHelper.read (in);
191            org.omg.CORBA.Any JavaDoc new_element = org.omg.mof.Reflective._ValueTypeHelper.read (in);
192            this.ref_add_value (feature, new_element);
193            out = $rh.createReply();
194          } catch (org.omg.mof.Reflective.MofError $ex) {
195            out = $rh.createExceptionReply ();
196            org.omg.mof.Reflective.MofErrorHelper.write (out, $ex);
197          }
198          break;
199        }
200
201        case 11: // org/omg/mof/Reflective/RefObject/ref_add_value_before
202
{
203          try {
204            org.omg.mof.Reflective.RefObject feature = org.omg.mof.Reflective.DesignatorTypeHelper.read (in);
205            org.omg.CORBA.Any JavaDoc new_element = org.omg.mof.Reflective._ValueTypeHelper.read (in);
206            org.omg.CORBA.Any JavaDoc before_element = org.omg.mof.Reflective._ValueTypeHelper.read (in);
207            this.ref_add_value_before (feature, new_element, before_element);
208            out = $rh.createReply();
209          } catch (org.omg.mof.Reflective.NotFound $ex) {
210            out = $rh.createExceptionReply ();
211            org.omg.mof.Reflective.NotFoundHelper.write (out, $ex);
212          } catch (org.omg.mof.Reflective.MofError $ex) {
213            out = $rh.createExceptionReply ();
214            org.omg.mof.Reflective.MofErrorHelper.write (out, $ex);
215          }
216          break;
217        }
218
219        case 12: // org/omg/mof/Reflective/RefObject/ref_add_value_at
220
{
221          try {
222            org.omg.mof.Reflective.RefObject feature = org.omg.mof.Reflective.DesignatorTypeHelper.read (in);
223            org.omg.CORBA.Any JavaDoc new_element = org.omg.mof.Reflective._ValueTypeHelper.read (in);
224            int position = in.read_ulong ();
225            this.ref_add_value_at (feature, new_element, position);
226            out = $rh.createReply();
227          } catch (org.omg.mof.Reflective.BadPosition $ex) {
228            out = $rh.createExceptionReply ();
229            org.omg.mof.Reflective.BadPositionHelper.write (out, $ex);
230          } catch (org.omg.mof.Reflective.MofError $ex) {
231            out = $rh.createExceptionReply ();
232            org.omg.mof.Reflective.MofErrorHelper.write (out, $ex);
233          }
234          break;
235        }
236
237        case 13: // org/omg/mof/Reflective/RefObject/ref_modify_value
238
{
239          try {
240            org.omg.mof.Reflective.RefObject feature = org.omg.mof.Reflective.DesignatorTypeHelper.read (in);
241            org.omg.CORBA.Any JavaDoc old_element = org.omg.mof.Reflective._ValueTypeHelper.read (in);
242            org.omg.CORBA.Any JavaDoc new_element = org.omg.mof.Reflective._ValueTypeHelper.read (in);
243            this.ref_modify_value (feature, old_element, new_element);
244            out = $rh.createReply();
245          } catch (org.omg.mof.Reflective.NotFound $ex) {
246            out = $rh.createExceptionReply ();
247            org.omg.mof.Reflective.NotFoundHelper.write (out, $ex);
248          } catch (org.omg.mof.Reflective.MofError $ex) {
249            out = $rh.createExceptionReply ();
250            org.omg.mof.Reflective.MofErrorHelper.write (out, $ex);
251          }
252          break;
253        }
254
255        case 14: // org/omg/mof/Reflective/RefObject/ref_modify_value_at
256
{
257          try {
258            org.omg.mof.Reflective.RefObject feature = org.omg.mof.Reflective.DesignatorTypeHelper.read (in);
259            org.omg.CORBA.Any JavaDoc new_element = org.omg.mof.Reflective._ValueTypeHelper.read (in);
260            int position = in.read_ulong ();
261            this.ref_modify_value_at (feature, new_element, position);
262            out = $rh.createReply();
263          } catch (org.omg.mof.Reflective.BadPosition $ex) {
264            out = $rh.createExceptionReply ();
265            org.omg.mof.Reflective.BadPositionHelper.write (out, $ex);
266          } catch (org.omg.mof.Reflective.MofError $ex) {
267            out = $rh.createExceptionReply ();
268            org.omg.mof.Reflective.MofErrorHelper.write (out, $ex);
269          }
270          break;
271        }
272
273        case 15: // org/omg/mof/Reflective/RefObject/ref_remove_value
274
{
275          try {
276            org.omg.mof.Reflective.RefObject feature = org.omg.mof.Reflective.DesignatorTypeHelper.read (in);
277            org.omg.CORBA.Any JavaDoc existing_element = org.omg.mof.Reflective._ValueTypeHelper.read (in);
278            this.ref_remove_value (feature, existing_element);
279            out = $rh.createReply();
280          } catch (org.omg.mof.Reflective.NotFound $ex) {
281            out = $rh.createExceptionReply ();
282            org.omg.mof.Reflective.NotFoundHelper.write (out, $ex);
283          } catch (org.omg.mof.Reflective.MofError $ex) {
284            out = $rh.createExceptionReply ();
285            org.omg.mof.Reflective.MofErrorHelper.write (out, $ex);
286          }
287          break;
288        }
289
290        case 16: // org/omg/mof/Reflective/RefObject/ref_remove_value_at
291
{
292          try {
293            org.omg.mof.Reflective.RefObject feature = org.omg.mof.Reflective.DesignatorTypeHelper.read (in);
294            int position = in.read_ulong ();
295            this.ref_remove_value_at (feature, position);
296            out = $rh.createReply();
297          } catch (org.omg.mof.Reflective.BadPosition $ex) {
298            out = $rh.createExceptionReply ();
299            org.omg.mof.Reflective.BadPositionHelper.write (out, $ex);
300          } catch (org.omg.mof.Reflective.MofError $ex) {
301            out = $rh.createExceptionReply ();
302            org.omg.mof.Reflective.MofErrorHelper.write (out, $ex);
303          }
304          break;
305        }
306
307        case 17: // org/omg/mof/Reflective/RefObject/ref_immediate_composite
308
{
309          org.omg.mof.Reflective.RefObject $result = null;
310          $result = this.ref_immediate_composite ();
311          out = $rh.createReply();
312          org.omg.mof.Reflective.RefObjectHelper.write (out, $result);
313          break;
314        }
315
316        case 18: // org/omg/mof/Reflective/RefObject/ref_outermost_composite
317
{
318          org.omg.mof.Reflective.RefObject $result = null;
319          $result = this.ref_outermost_composite ();
320          out = $rh.createReply();
321          org.omg.mof.Reflective.RefObjectHelper.write (out, $result);
322          break;
323        }
324
325        case 19: // org/omg/mof/Reflective/RefObject/ref_invoke_operation
326
{
327          try {
328            org.omg.mof.Reflective.RefObject requested_operation = org.omg.mof.Reflective.DesignatorTypeHelper.read (in);
329            org.omg.mof.Reflective.ValueTypeListHolder args = new org.omg.mof.Reflective.ValueTypeListHolder ();
330            args.value = org.omg.mof.Reflective.ValueTypeListHelper.read (in);
331            org.omg.CORBA.Any JavaDoc $result = null;
332            $result = this.ref_invoke_operation (requested_operation, args);
333            out = $rh.createReply();
334            out.write_any ($result);
335            org.omg.mof.Reflective.ValueTypeListHelper.write (out, args.value);
336          } catch (org.omg.mof.Reflective.OtherException $ex) {
337            out = $rh.createExceptionReply ();
338            org.omg.mof.Reflective.OtherExceptionHelper.write (out, $ex);
339          } catch (org.omg.mof.Reflective.MofError $ex) {
340            out = $rh.createExceptionReply ();
341            org.omg.mof.Reflective.MofErrorHelper.write (out, $ex);
342          }
343          break;
344        }
345
346        case 20: // org/omg/mof/Reflective/RefBaseObject/ref_mof_id
347
{
348          String JavaDoc $result = null;
349          $result = this.ref_mof_id ();
350          out = $rh.createReply();
351          out.write_string ($result);
352          break;
353        }
354
355        case 21: // org/omg/mof/Reflective/RefBaseObject/ref_meta_object
356
{
357          org.omg.mof.Reflective.RefObject $result = null;
358          $result = this.ref_meta_object ();
359          out = $rh.createReply();
360          org.omg.mof.Reflective.RefObjectHelper.write (out, $result);
361          break;
362        }
363
364        case 22: // org/omg/mof/Reflective/RefBaseObject/ref_itself
365
{
366          org.omg.mof.Reflective.RefBaseObject other_object = org.omg.mof.Reflective.RefBaseObjectHelper.read (in);
367          boolean $result = false;
368          $result = this.ref_itself (other_object);
369          out = $rh.createReply();
370          out.write_boolean ($result);
371          break;
372        }
373
374        case 23: // org/omg/mof/Reflective/RefBaseObject/ref_immediate_package
375
{
376          org.omg.mof.Reflective._RefPackage $result = null;
377          $result = this.ref_immediate_package ();
378          out = $rh.createReply();
379          org.omg.mof.Reflective._RefPackageHelper.write (out, $result);
380          break;
381        }
382
383        case 24: // org/omg/mof/Reflective/RefBaseObject/ref_outermost_package
384
{
385          org.omg.mof.Reflective._RefPackage $result = null;
386          $result = this.ref_outermost_package ();
387          out = $rh.createReply();
388          org.omg.mof.Reflective._RefPackageHelper.write (out, $result);
389          break;
390        }
391
392        case 25: // org/omg/mof/Reflective/RefBaseObject/ref_delete
393
{
394          try {
395            this.ref_delete ();
396            out = $rh.createReply();
397          } catch (org.omg.mof.Reflective.MofError $ex) {
398            out = $rh.createExceptionReply ();
399            org.omg.mof.Reflective.MofErrorHelper.write (out, $ex);
400          }
401          break;
402        }
403
404        default:
405          throw new org.omg.CORBA.BAD_OPERATION JavaDoc (0, org.omg.CORBA.CompletionStatus.COMPLETED_MAYBE);
406     }
407
408     return out;
409   } // _invoke
410

411   // Type-specific CORBA::Object operations
412
private static String JavaDoc[] __ids = {
413     "IDL:org/omg/mof/Model/ConstraintClass:1.0",
414     "IDL:org/omg/mof/Model/ModelElementClass:1.0",
415     "IDL:org/omg/mof/Reflective/RefObject:1.0",
416     "IDL:org/omg/mof/Reflective/RefBaseObject:1.0"};
417
418   public String JavaDoc[] _all_interfaces (org.omg.PortableServer.POA JavaDoc poa, byte[] objectId)
419   {
420     return (String JavaDoc[])__ids.clone ();
421   }
422
423   public ConstraintClass _this()
424   {
425     return ConstraintClassHelper.narrow(
426     super._this_object());
427   }
428
429   public ConstraintClass _this(org.omg.CORBA.ORB JavaDoc orb)
430   {
431     return ConstraintClassHelper.narrow(
432     super._this_object(orb));
433   }
434
435
436 } // class ConstraintClassPOA
437
Popular Tags