00001 package SctTestApi; 00002 00003 00015 abstract public class ConfigurationHelper 00016 { 00017 private static String _id = "IDL:SctTestApi/Configuration:1.0"; 00018 00019 public static void insert (org.omg.CORBA.Any a, SctTestApi.Configuration that) 00020 { 00021 org.omg.CORBA.portable.OutputStream out = a.create_output_stream (); 00022 a.type (type ()); 00023 write (out, that); 00024 a.read_value (out.create_input_stream (), type ()); 00025 } 00026 00027 public static SctTestApi.Configuration extract (org.omg.CORBA.Any a) 00028 { 00029 return read (a.create_input_stream ()); 00030 } 00031 00032 private static org.omg.CORBA.TypeCode __typeCode = null; 00033 synchronized public static org.omg.CORBA.TypeCode type () 00034 { 00035 if (__typeCode == null) 00036 { 00037 __typeCode = org.omg.CORBA.ORB.init ().create_interface_tc (SctTestApi.ConfigurationHelper.id (), "Configuration"); 00038 } 00039 return __typeCode; 00040 } 00041 00042 public static String id () 00043 { 00044 return _id; 00045 } 00046 00047 public static SctTestApi.Configuration read (org.omg.CORBA.portable.InputStream istream) 00048 { 00049 return narrow (istream.read_Object (_ConfigurationStub.class)); 00050 } 00051 00052 public static void write (org.omg.CORBA.portable.OutputStream ostream, SctTestApi.Configuration value) 00053 { 00054 ostream.write_Object ((org.omg.CORBA.Object) value); 00055 } 00056 00057 public static SctTestApi.Configuration narrow (org.omg.CORBA.Object obj) 00058 { 00059 if (obj == null) 00060 return null; 00061 else if (obj instanceof SctTestApi.Configuration) 00062 return (SctTestApi.Configuration)obj; 00063 else if (!obj._is_a (id ())) 00064 throw new org.omg.CORBA.BAD_PARAM (); 00065 else 00066 { 00067 org.omg.CORBA.portable.Delegate delegate = ((org.omg.CORBA.portable.ObjectImpl)obj)._get_delegate (); 00068 SctTestApi._ConfigurationStub stub = new SctTestApi._ConfigurationStub (); 00069 stub._set_delegate(delegate); 00070 return stub; 00071 } 00072 } 00073 00074 }