KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > gcc > org > omg > GIOP > LocateRequestHeader_1_0Helper


1 package gcc.org.omg.GIOP;
2
3
4 /**
5 * gcc/org/omg/GIOP/LocateRequestHeader_1_0Helper.java .
6 * Generated by the IDL-to-Java compiler (portable), version "3.1"
7 * from ../idl/GIOP.idl
8 * Wednesday, December 8, 2004 11:54:40 AM EST
9 */

10
11
12 // GIOP 1.0
13
abstract public class LocateRequestHeader_1_0Helper
14 {
15   private static String JavaDoc _id = "IDL:omg.org/GIOP/LocateRequestHeader_1_0:1.0";
16
17   public static void insert (org.omg.CORBA.Any JavaDoc a, gcc.org.omg.GIOP.LocateRequestHeader_1_0 that)
18   {
19     org.omg.CORBA.portable.OutputStream JavaDoc out = a.create_output_stream ();
20     a.type (type ());
21     write (out, that);
22     a.read_value (out.create_input_stream (), type ());
23   }
24
25   public static gcc.org.omg.GIOP.LocateRequestHeader_1_0 extract (org.omg.CORBA.Any JavaDoc a)
26   {
27     return read (a.create_input_stream ());
28   }
29
30   private static org.omg.CORBA.TypeCode JavaDoc __typeCode = null;
31   private static boolean __active = false;
32   synchronized public static org.omg.CORBA.TypeCode JavaDoc type ()
33   {
34     if (__typeCode == null)
35     {
36       synchronized (org.omg.CORBA.TypeCode JavaDoc.class)
37       {
38         if (__typeCode == null)
39         {
40           if (__active)
41           {
42             return org.omg.CORBA.ORB.init().create_recursive_tc ( _id );
43           }
44           __active = true;
45           org.omg.CORBA.StructMember JavaDoc[] _members0 = new org.omg.CORBA.StructMember JavaDoc [2];
46           org.omg.CORBA.TypeCode JavaDoc _tcOf_members0 = null;
47           _tcOf_members0 = org.omg.CORBA.ORB.init ().get_primitive_tc (org.omg.CORBA.TCKind.tk_ulong);
48           _members0[0] = new org.omg.CORBA.StructMember JavaDoc (
49             "request_id",
50             _tcOf_members0,
51             null);
52           _tcOf_members0 = org.omg.CORBA.ORB.init ().get_primitive_tc (org.omg.CORBA.TCKind.tk_octet);
53           _tcOf_members0 = org.omg.CORBA.ORB.init ().create_sequence_tc (0, _tcOf_members0);
54           _members0[1] = new org.omg.CORBA.StructMember JavaDoc (
55             "object_key",
56             _tcOf_members0,
57             null);
58           __typeCode = org.omg.CORBA.ORB.init ().create_struct_tc (gcc.org.omg.GIOP.LocateRequestHeader_1_0Helper.id (), "LocateRequestHeader_1_0", _members0);
59           __active = false;
60         }
61       }
62     }
63     return __typeCode;
64   }
65
66   public static String JavaDoc id ()
67   {
68     return _id;
69   }
70
71   public static gcc.org.omg.GIOP.LocateRequestHeader_1_0 read (org.omg.CORBA.portable.InputStream JavaDoc istream)
72   {
73     gcc.org.omg.GIOP.LocateRequestHeader_1_0 value = new gcc.org.omg.GIOP.LocateRequestHeader_1_0 ();
74     value.request_id = istream.read_ulong ();
75     int _len0 = istream.read_long ();
76     value.object_key = new byte[_len0];
77     istream.read_octet_array (value.object_key, 0, _len0);
78     return value;
79   }
80
81   public static void write (org.omg.CORBA.portable.OutputStream JavaDoc ostream, gcc.org.omg.GIOP.LocateRequestHeader_1_0 value)
82   {
83     ostream.write_ulong (value.request_id);
84     ostream.write_long (value.object_key.length);
85     ostream.write_octet_array (value.object_key, 0, value.object_key.length);
86   }
87
88 }
89
Popular Tags