KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > omg > PortableInterceptor > ObjectReferenceFactoryHelper


1 package org.omg.PortableInterceptor;
2
3
4 /**
5 * org/omg/PortableInterceptor/ObjectReferenceFactoryHelper.java .
6 * Generated by the IDL-to-Java compiler (portable), version "3.2"
7 * from ../../../../src/share/classes/org/omg/PortableInterceptor/Interceptors.idl
8 * Saturday, February 9, 2008 9:40:08 AM GMT
9 */

10
11
12 /** The object reference factory. This provides the capability of
13   * creating an object reference.
14   */

15 abstract public class ObjectReferenceFactoryHelper
16 {
17   private static String JavaDoc _id = "IDL:omg.org/PortableInterceptor/ObjectReferenceFactory:1.0";
18
19
20   public static void insert (org.omg.CORBA.Any JavaDoc a, org.omg.PortableInterceptor.ObjectReferenceFactory JavaDoc that)
21   {
22     org.omg.CORBA.portable.OutputStream JavaDoc out = a.create_output_stream ();
23     a.type (type ());
24     write (out, that);
25     a.read_value (out.create_input_stream (), type ());
26   }
27
28   public static org.omg.PortableInterceptor.ObjectReferenceFactory JavaDoc extract (org.omg.CORBA.Any JavaDoc a)
29   {
30     return read (a.create_input_stream ());
31   }
32
33   private static org.omg.CORBA.TypeCode JavaDoc __typeCode = null;
34   private static boolean __active = false;
35   synchronized public static org.omg.CORBA.TypeCode JavaDoc type ()
36   {
37     if (__typeCode == null)
38     {
39       synchronized (org.omg.CORBA.TypeCode JavaDoc.class)
40       {
41         if (__typeCode == null)
42         {
43           if (__active)
44           {
45             return org.omg.CORBA.ORB.init().create_recursive_tc ( _id );
46           }
47           __active = true;
48           org.omg.CORBA.ValueMember JavaDoc[] _members0 = new org.omg.CORBA.ValueMember JavaDoc[0];
49           org.omg.CORBA.TypeCode JavaDoc _tcOf_members0 = null;
50           __typeCode = org.omg.CORBA.ORB.init ().create_value_tc (_id, "ObjectReferenceFactory", org.omg.CORBA.VM_ABSTRACT.value, null, _members0);
51           __active = false;
52         }
53       }
54     }
55     return __typeCode;
56   }
57
58   public static String JavaDoc id ()
59   {
60     return _id;
61   }
62
63   public static org.omg.PortableInterceptor.ObjectReferenceFactory JavaDoc read (org.omg.CORBA.portable.InputStream JavaDoc istream)
64   {
65     return (org.omg.PortableInterceptor.ObjectReferenceFactory JavaDoc)((org.omg.CORBA_2_3.portable.InputStream JavaDoc) istream).read_value (id ());
66   }
67
68   public static void write (org.omg.CORBA.portable.OutputStream JavaDoc ostream, org.omg.PortableInterceptor.ObjectReferenceFactory JavaDoc value)
69   {
70     ((org.omg.CORBA_2_3.portable.OutputStream JavaDoc) ostream).write_value (value, id ());
71   }
72
73
74 }
75
Popular Tags