KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > omg > mof > Reflective > _RefAssociationStub


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

10
11
12 // end of RefObject interface
13
public class _RefAssociationStub extends org.omg.CORBA.portable.ObjectImpl JavaDoc implements org.omg.mof.Reflective.RefAssociation
14 {
15
16   public org.omg.mof.Reflective.RefObject[][] ref_all_links ()
17   {
18     org.omg.CORBA.portable.InputStream JavaDoc $in = null;
19     try {
20        org.omg.CORBA.portable.OutputStream JavaDoc $out = _request ("ref_all_links", true);
21        $in = _invoke ($out);
22        org.omg.mof.Reflective.RefObject $result[][] = org.omg.mof.Reflective.LinkSetHelper.read ($in);
23        return $result;
24     } catch (org.omg.CORBA.portable.ApplicationException JavaDoc $ex) {
25        $in = $ex.getInputStream ();
26        String JavaDoc _id = $ex.getId ();
27        throw new org.omg.CORBA.MARSHAL JavaDoc (_id);
28     } catch (org.omg.CORBA.portable.RemarshalException JavaDoc $rm) {
29        return ref_all_links ();
30     } finally {
31         _releaseReply ($in);
32     }
33   } // ref_all_links
34

35   public boolean ref_link_exists (org.omg.mof.Reflective.RefObject[] some_link) throws org.omg.mof.Reflective.MofError
36   {
37     org.omg.CORBA.portable.InputStream JavaDoc $in = null;
38     try {
39        org.omg.CORBA.portable.OutputStream JavaDoc $out = _request ("ref_link_exists", true);
40        org.omg.mof.Reflective.LinkHelper.write ($out, some_link);
41        $in = _invoke ($out);
42        boolean $result = $in.read_boolean ();
43        return $result;
44     } catch (org.omg.CORBA.portable.ApplicationException JavaDoc $ex) {
45        $in = $ex.getInputStream ();
46        String JavaDoc _id = $ex.getId ();
47        if (_id.equals ("IDL:org/omg/mof/Reflective/MofError:1.0"))
48           throw org.omg.mof.Reflective.MofErrorHelper.read ($in);
49        else
50             throw new org.omg.CORBA.MARSHAL JavaDoc (_id);
51     } catch (org.omg.CORBA.portable.RemarshalException JavaDoc $rm) {
52        return ref_link_exists (some_link);
53     } finally {
54         _releaseReply ($in);
55     }
56   } // ref_link_exists
57

58   public org.omg.mof.Reflective.RefObject[] ref_query (org.omg.mof.Reflective.RefObject query_end, org.omg.mof.Reflective.RefObject query_object) throws org.omg.mof.Reflective.MofError
59   {
60     org.omg.CORBA.portable.InputStream JavaDoc $in = null;
61     try {
62        org.omg.CORBA.portable.OutputStream JavaDoc $out = _request ("ref_query", true);
63        org.omg.mof.Reflective.DesignatorTypeHelper.write ($out, query_end);
64        org.omg.mof.Reflective.RefObjectHelper.write ($out, query_object);
65        $in = _invoke ($out);
66        org.omg.mof.Reflective.RefObject $result[] = org.omg.mof.Reflective.RefObjectUListHelper.read ($in);
67        return $result;
68     } catch (org.omg.CORBA.portable.ApplicationException JavaDoc $ex) {
69        $in = $ex.getInputStream ();
70        String JavaDoc _id = $ex.getId ();
71        if (_id.equals ("IDL:org/omg/mof/Reflective/MofError:1.0"))
72           throw org.omg.mof.Reflective.MofErrorHelper.read ($in);
73        else
74             throw new org.omg.CORBA.MARSHAL JavaDoc (_id);
75     } catch (org.omg.CORBA.portable.RemarshalException JavaDoc $rm) {
76        return ref_query (query_end, query_object);
77     } finally {
78         _releaseReply ($in);
79     }
80   } // ref_query
81

82   public void ref_add_link (org.omg.mof.Reflective.RefObject[] new_link) throws org.omg.mof.Reflective.MofError
83   {
84     org.omg.CORBA.portable.InputStream JavaDoc $in = null;
85     try {
86        org.omg.CORBA.portable.OutputStream JavaDoc $out = _request ("ref_add_link", true);
87        org.omg.mof.Reflective.LinkHelper.write ($out, new_link);
88        $in = _invoke ($out);
89     } catch (org.omg.CORBA.portable.ApplicationException JavaDoc $ex) {
90        $in = $ex.getInputStream ();
91        String JavaDoc _id = $ex.getId ();
92        if (_id.equals ("IDL:org/omg/mof/Reflective/MofError:1.0"))
93           throw org.omg.mof.Reflective.MofErrorHelper.read ($in);
94        else
95             throw new org.omg.CORBA.MARSHAL JavaDoc (_id);
96     } catch (org.omg.CORBA.portable.RemarshalException JavaDoc $rm) {
97        ref_add_link (new_link);
98     } finally {
99         _releaseReply ($in);
100     }
101   } // ref_add_link
102

103   public void ref_add_link_before (org.omg.mof.Reflective.RefObject[] new_link, org.omg.mof.Reflective.RefObject position_end, org.omg.mof.Reflective.RefObject before) throws org.omg.mof.Reflective.NotFound, org.omg.mof.Reflective.MofError
104   {
105     org.omg.CORBA.portable.InputStream JavaDoc $in = null;
106     try {
107        org.omg.CORBA.portable.OutputStream JavaDoc $out = _request ("ref_add_link_before", true);
108        org.omg.mof.Reflective.LinkHelper.write ($out, new_link);
109        org.omg.mof.Reflective.DesignatorTypeHelper.write ($out, position_end);
110        org.omg.mof.Reflective.RefObjectHelper.write ($out, before);
111        $in = _invoke ($out);
112     } catch (org.omg.CORBA.portable.ApplicationException JavaDoc $ex) {
113        $in = $ex.getInputStream ();
114        String JavaDoc _id = $ex.getId ();
115        if (_id.equals ("IDL:org/omg/mof/Reflective/NotFound:1.0"))
116           throw org.omg.mof.Reflective.NotFoundHelper.read ($in);
117        else if (_id.equals ("IDL:org/omg/mof/Reflective/MofError:1.0"))
118           throw org.omg.mof.Reflective.MofErrorHelper.read ($in);
119        else
120             throw new org.omg.CORBA.MARSHAL JavaDoc (_id);
121     } catch (org.omg.CORBA.portable.RemarshalException JavaDoc $rm) {
122        ref_add_link_before (new_link, position_end, before);
123     } finally {
124         _releaseReply ($in);
125     }
126   } // ref_add_link_before
127

128   public void ref_modify_link (org.omg.mof.Reflective.RefObject[] old_link, org.omg.mof.Reflective.RefObject position_end, org.omg.mof.Reflective.RefObject new_object) throws org.omg.mof.Reflective.NotFound, org.omg.mof.Reflective.MofError
129   {
130     org.omg.CORBA.portable.InputStream JavaDoc $in = null;
131     try {
132        org.omg.CORBA.portable.OutputStream JavaDoc $out = _request ("ref_modify_link", true);
133        org.omg.mof.Reflective.LinkHelper.write ($out, old_link);
134        org.omg.mof.Reflective.DesignatorTypeHelper.write ($out, position_end);
135        org.omg.mof.Reflective.RefObjectHelper.write ($out, new_object);
136        $in = _invoke ($out);
137     } catch (org.omg.CORBA.portable.ApplicationException JavaDoc $ex) {
138        $in = $ex.getInputStream ();
139        String JavaDoc _id = $ex.getId ();
140        if (_id.equals ("IDL:org/omg/mof/Reflective/NotFound:1.0"))
141           throw org.omg.mof.Reflective.NotFoundHelper.read ($in);
142        else if (_id.equals ("IDL:org/omg/mof/Reflective/MofError:1.0"))
143           throw org.omg.mof.Reflective.MofErrorHelper.read ($in);
144        else
145             throw new org.omg.CORBA.MARSHAL JavaDoc (_id);
146     } catch (org.omg.CORBA.portable.RemarshalException JavaDoc $rm) {
147        ref_modify_link (old_link, position_end, new_object);
148     } finally {
149         _releaseReply ($in);
150     }
151   } // ref_modify_link
152

153   public void ref_remove_link (org.omg.mof.Reflective.RefObject[] old_link) throws org.omg.mof.Reflective.NotFound, org.omg.mof.Reflective.MofError
154   {
155     org.omg.CORBA.portable.InputStream JavaDoc $in = null;
156     try {
157        org.omg.CORBA.portable.OutputStream JavaDoc $out = _request ("ref_remove_link", true);
158        org.omg.mof.Reflective.LinkHelper.write ($out, old_link);
159        $in = _invoke ($out);
160     } catch (org.omg.CORBA.portable.ApplicationException JavaDoc $ex) {
161        $in = $ex.getInputStream ();
162        String JavaDoc _id = $ex.getId ();
163        if (_id.equals ("IDL:org/omg/mof/Reflective/NotFound:1.0"))
164           throw org.omg.mof.Reflective.NotFoundHelper.read ($in);
165        else if (_id.equals ("IDL:org/omg/mof/Reflective/MofError:1.0"))
166           throw org.omg.mof.Reflective.MofErrorHelper.read ($in);
167        else
168             throw new org.omg.CORBA.MARSHAL JavaDoc (_id);
169     } catch (org.omg.CORBA.portable.RemarshalException JavaDoc $rm) {
170        ref_remove_link (old_link);
171     } finally {
172         _releaseReply ($in);
173     }
174   } // ref_remove_link
175

176   public String JavaDoc ref_mof_id ()
177   {
178     org.omg.CORBA.portable.InputStream JavaDoc $in = null;
179     try {
180        org.omg.CORBA.portable.OutputStream JavaDoc $out = _request ("ref_mof_id", true);
181        $in = _invoke ($out);
182        String JavaDoc $result = $in.read_string ();
183        return $result;
184     } catch (org.omg.CORBA.portable.ApplicationException JavaDoc $ex) {
185        $in = $ex.getInputStream ();
186        String JavaDoc _id = $ex.getId ();
187        throw new org.omg.CORBA.MARSHAL JavaDoc (_id);
188     } catch (org.omg.CORBA.portable.RemarshalException JavaDoc $rm) {
189        return ref_mof_id ();
190     } finally {
191         _releaseReply ($in);
192     }
193   } // ref_mof_id
194

195   public org.omg.mof.Reflective.RefObject ref_meta_object ()
196   {
197     org.omg.CORBA.portable.InputStream JavaDoc $in = null;
198     try {
199        org.omg.CORBA.portable.OutputStream JavaDoc $out = _request ("ref_meta_object", true);
200        $in = _invoke ($out);
201        org.omg.mof.Reflective.RefObject $result = org.omg.mof.Reflective.DesignatorTypeHelper.read ($in);
202        return $result;
203     } catch (org.omg.CORBA.portable.ApplicationException JavaDoc $ex) {
204        $in = $ex.getInputStream ();
205        String JavaDoc _id = $ex.getId ();
206        throw new org.omg.CORBA.MARSHAL JavaDoc (_id);
207     } catch (org.omg.CORBA.portable.RemarshalException JavaDoc $rm) {
208        return ref_meta_object ();
209     } finally {
210         _releaseReply ($in);
211     }
212   } // ref_meta_object
213

214   public boolean ref_itself (org.omg.mof.Reflective.RefBaseObject other_object)
215   {
216     org.omg.CORBA.portable.InputStream JavaDoc $in = null;
217     try {
218        org.omg.CORBA.portable.OutputStream JavaDoc $out = _request ("ref_itself", true);
219        org.omg.mof.Reflective.RefBaseObjectHelper.write ($out, other_object);
220        $in = _invoke ($out);
221        boolean $result = $in.read_boolean ();
222        return $result;
223     } catch (org.omg.CORBA.portable.ApplicationException JavaDoc $ex) {
224        $in = $ex.getInputStream ();
225        String JavaDoc _id = $ex.getId ();
226        throw new org.omg.CORBA.MARSHAL JavaDoc (_id);
227     } catch (org.omg.CORBA.portable.RemarshalException JavaDoc $rm) {
228        return ref_itself (other_object);
229     } finally {
230         _releaseReply ($in);
231     }
232   } // ref_itself
233

234   public org.omg.mof.Reflective._RefPackage ref_immediate_package ()
235   {
236     org.omg.CORBA.portable.InputStream JavaDoc $in = null;
237     try {
238        org.omg.CORBA.portable.OutputStream JavaDoc $out = _request ("ref_immediate_package", true);
239        $in = _invoke ($out);
240        org.omg.mof.Reflective._RefPackage $result = org.omg.mof.Reflective._RefPackageHelper.read ($in);
241        return $result;
242     } catch (org.omg.CORBA.portable.ApplicationException JavaDoc $ex) {
243        $in = $ex.getInputStream ();
244        String JavaDoc _id = $ex.getId ();
245        throw new org.omg.CORBA.MARSHAL JavaDoc (_id);
246     } catch (org.omg.CORBA.portable.RemarshalException JavaDoc $rm) {
247        return ref_immediate_package ();
248     } finally {
249         _releaseReply ($in);
250     }
251   } // ref_immediate_package
252

253   public org.omg.mof.Reflective._RefPackage ref_outermost_package ()
254   {
255     org.omg.CORBA.portable.InputStream JavaDoc $in = null;
256     try {
257        org.omg.CORBA.portable.OutputStream JavaDoc $out = _request ("ref_outermost_package", true);
258        $in = _invoke ($out);
259        org.omg.mof.Reflective._RefPackage $result = org.omg.mof.Reflective._RefPackageHelper.read ($in);
260        return $result;
261     } catch (org.omg.CORBA.portable.ApplicationException JavaDoc $ex) {
262        $in = $ex.getInputStream ();
263        String JavaDoc _id = $ex.getId ();
264        throw new org.omg.CORBA.MARSHAL JavaDoc (_id);
265     } catch (org.omg.CORBA.portable.RemarshalException JavaDoc $rm) {
266        return ref_outermost_package ();
267     } finally {
268         _releaseReply ($in);
269     }
270   } // ref_outermost_package
271

272   public void ref_delete () throws org.omg.mof.Reflective.MofError
273   {
274     org.omg.CORBA.portable.InputStream JavaDoc $in = null;
275     try {
276        org.omg.CORBA.portable.OutputStream JavaDoc $out = _request ("ref_delete", true);
277        $in = _invoke ($out);
278     } catch (org.omg.CORBA.portable.ApplicationException JavaDoc $ex) {
279        $in = $ex.getInputStream ();
280        String JavaDoc _id = $ex.getId ();
281        if (_id.equals ("IDL:org/omg/mof/Reflective/MofError:1.0"))
282           throw org.omg.mof.Reflective.MofErrorHelper.read ($in);
283        else
284             throw new org.omg.CORBA.MARSHAL JavaDoc (_id);
285     } catch (org.omg.CORBA.portable.RemarshalException JavaDoc $rm) {
286        ref_delete ();
287     } finally {
288         _releaseReply ($in);
289     }
290   } // ref_delete
291

292   // Type-specific CORBA::Object operations
293
private static String JavaDoc[] __ids = {
294     "IDL:org/omg/mof/Reflective/RefAssociation:1.0",
295     "IDL:org/omg/mof/Reflective/RefBaseObject:1.0"};
296
297   public String JavaDoc[] _ids ()
298   {
299     return (String JavaDoc[])__ids.clone ();
300   }
301
302   private void readObject (java.io.ObjectInputStream JavaDoc s) throws java.io.IOException JavaDoc
303   {
304      String JavaDoc str = s.readUTF ();
305      String JavaDoc[] args = null;
306      java.util.Properties JavaDoc props = null;
307      org.omg.CORBA.Object JavaDoc obj = org.omg.CORBA.ORB.init (args, props).string_to_object (str);
308      org.omg.CORBA.portable.Delegate JavaDoc delegate = ((org.omg.CORBA.portable.ObjectImpl JavaDoc) obj)._get_delegate ();
309      _set_delegate (delegate);
310   }
311
312   private void writeObject (java.io.ObjectOutputStream JavaDoc s) throws java.io.IOException JavaDoc
313   {
314      String JavaDoc[] args = null;
315      java.util.Properties JavaDoc props = null;
316      String JavaDoc str = org.omg.CORBA.ORB.init (args, props).object_to_string (this);
317      s.writeUTF (str);
318   }
319 } // class _RefAssociationStub
320
Popular Tags