1 23 24 28 package com.sun.jts.otsidl; 29 30 31 37 38 39 abstract public class JCoordinatorHelper 41 { 42 private static String _id = "IDL:otsidl/JCoordinator:1.0"; 43 44 public static void insert (org.omg.CORBA.Any a, com.sun.jts.otsidl.JCoordinator that) 45 { 46 org.omg.CORBA.portable.OutputStream out = a.create_output_stream (); 47 a.type (type ()); 48 write (out, that); 49 a.read_value (out.create_input_stream (), type ()); 50 } 51 52 public static com.sun.jts.otsidl.JCoordinator extract (org.omg.CORBA.Any a) 53 { 54 return read (a.create_input_stream ()); 55 } 56 57 private static org.omg.CORBA.TypeCode __typeCode = null; 58 synchronized public static org.omg.CORBA.TypeCode type () 59 { 60 if (__typeCode == null) 61 { 62 __typeCode = org.omg.CORBA.ORB.init ().create_interface_tc (com.sun.jts.otsidl.JCoordinatorHelper.id (), "JCoordinator"); 63 } 64 return __typeCode; 65 } 66 67 public static String id () 68 { 69 return _id; 70 } 71 72 public static com.sun.jts.otsidl.JCoordinator read (org.omg.CORBA.portable.InputStream istream) 73 { 74 return narrow (istream.read_Object (_JCoordinatorStub.class)); 75 } 76 77 public static void write (org.omg.CORBA.portable.OutputStream ostream, com.sun.jts.otsidl.JCoordinator value) 78 { 79 ostream.write_Object ((org.omg.CORBA.Object ) value); 80 } 81 82 public static com.sun.jts.otsidl.JCoordinator narrow (org.omg.CORBA.Object obj) 83 { 84 if (obj == null) 85 return null; 86 else if (obj instanceof com.sun.jts.otsidl.JCoordinator) 87 return (com.sun.jts.otsidl.JCoordinator)obj; 88 else if (!obj._is_a (id ())) 89 throw new org.omg.CORBA.BAD_PARAM (); 90 else 91 { 92 org.omg.CORBA.portable.Delegate delegate = ((org.omg.CORBA.portable.ObjectImpl )obj)._get_delegate (); 93 com.sun.jts.otsidl._JCoordinatorStub stub = new com.sun.jts.otsidl._JCoordinatorStub (); 94 stub._set_delegate(delegate); 95 return stub; 96 } 97 } 98 99 } 100 | Popular Tags |