1. package org.omg.IOP;
  2. /**
  3. * org/omg/IOP/CodecFactoryHelper.java .
  4. * Generated by the IDL-to-Java compiler (portable), version "3.1"
  5. * from ../../../../src/share/classes/org/omg/PortableInterceptor/IOP.idl
  6. * Monday, February 23, 2004 7:03:03 AM GMT
  7. */
  8. /**
  9. * <code>Codecs</code> are obtained from the <code>CodecFactory</code>.
  10. * The <code>CodecFactory</code> is obtained through a call to
  11. * <code>ORB.resolve_initial_references( "CodecFactory" )</code>.
  12. */
  13. abstract public class CodecFactoryHelper
  14. {
  15. private static String _id = "IDL:omg.org/IOP/CodecFactory:1.0";
  16. public static void insert (org.omg.CORBA.Any a, org.omg.IOP.CodecFactory that)
  17. {
  18. org.omg.CORBA.portable.OutputStream out = a.create_output_stream ();
  19. a.type (type ());
  20. write (out, that);
  21. a.read_value (out.create_input_stream (), type ());
  22. }
  23. public static org.omg.IOP.CodecFactory extract (org.omg.CORBA.Any a)
  24. {
  25. return read (a.create_input_stream ());
  26. }
  27. private static org.omg.CORBA.TypeCode __typeCode = null;
  28. synchronized public static org.omg.CORBA.TypeCode type ()
  29. {
  30. if (__typeCode == null)
  31. {
  32. __typeCode = org.omg.CORBA.ORB.init ().create_interface_tc (org.omg.IOP.CodecFactoryHelper.id (), "CodecFactory");
  33. }
  34. return __typeCode;
  35. }
  36. public static String id ()
  37. {
  38. return _id;
  39. }
  40. public static org.omg.IOP.CodecFactory read (org.omg.CORBA.portable.InputStream istream)
  41. {
  42. throw new org.omg.CORBA.MARSHAL ();
  43. }
  44. public static void write (org.omg.CORBA.portable.OutputStream ostream, org.omg.IOP.CodecFactory value)
  45. {
  46. throw new org.omg.CORBA.MARSHAL ();
  47. }
  48. public static org.omg.IOP.CodecFactory narrow (org.omg.CORBA.Object obj)
  49. {
  50. if (obj == null)
  51. return null;
  52. else if (obj instanceof org.omg.IOP.CodecFactory)
  53. return (org.omg.IOP.CodecFactory)obj;
  54. else
  55. throw new org.omg.CORBA.BAD_PARAM ();
  56. }
  57. }