1 /***
2 * FIPA_Agent_97Helper.java
3 * Generated by the IDL-to-Java compiler (portable), version "3.0"
4 * from FIPA_Agent_97.idl
5 * 08 August 2000 13:12:52 o'clock BST
6 */
7 package fipa97;
8
9 abstract public class FIPA_Agent_97Helper
10 {
11 private static String _id = "IDL:FIPA_Agent_97:1.0";
12
13 public static void insert (org.omg.CORBA.Any a, FIPA_Agent_97 that)
14 {
15 org.omg.CORBA.portable.OutputStream out = a.create_output_stream ();
16 a.type (type ());
17 write (out, that);
18 a.read_value (out.create_input_stream (), type ());
19 }
20
21 public static FIPA_Agent_97 extract (org.omg.CORBA.Any a)
22 {
23 return read (a.create_input_stream ());
24 }
25
26 private static org.omg.CORBA.TypeCode __typeCode = null;
27 synchronized public static org.omg.CORBA.TypeCode type ()
28 {
29 if (__typeCode == null)
30 {
31 __typeCode = org.omg.CORBA.ORB.init ().create_interface_tc (FIPA_Agent_97Helper.id (), "FIPA_Agent_97");
32 }
33 return __typeCode;
34 }
35
36 public static String id ()
37 {
38 return _id;
39 }
40
41 public static FIPA_Agent_97 read (org.omg.CORBA.portable.InputStream istream)
42 {
43 return narrow (istream.read_Object (_FIPA_Agent_97Stub.class));
44 }
45
46 public static void write (org.omg.CORBA.portable.OutputStream ostream, FIPA_Agent_97 value)
47 {
48 ostream.write_Object ((org.omg.CORBA.Object) value);
49 }
50
51 public static FIPA_Agent_97 narrow (org.omg.CORBA.Object obj)
52 {
53 if (obj == null)
54 return null;
55 else if (obj instanceof FIPA_Agent_97)
56 return (FIPA_Agent_97)obj;
57 else if (!obj._is_a (id ()))
58 throw new org.omg.CORBA.BAD_PARAM ();
59 else
60 {
61 org.omg.CORBA.portable.Delegate delegate = ((org.omg.CORBA.portable.ObjectImpl)obj)._get_delegate ();
62 return new _FIPA_Agent_97Stub (delegate);
63 }
64 }
65
66 }