1. package org.omg.PortableServer.POAPackage;
  2. /**
  3. * org/omg/PortableServer/POAPackage/InvalidPolicyHelper.java .
  4. * Generated by the IDL-to-Java compiler (portable), version "3.1"
  5. * from ../../../../src/share/classes/org/omg/PortableServer/poa.idl
  6. * Monday, February 23, 2004 7:03:02 AM GMT
  7. */
  8. abstract public class InvalidPolicyHelper
  9. {
  10. private static String _id = "IDL:omg.org/PortableServer/POA/InvalidPolicy:1.0";
  11. public static void insert (org.omg.CORBA.Any a, org.omg.PortableServer.POAPackage.InvalidPolicy that)
  12. {
  13. org.omg.CORBA.portable.OutputStream out = a.create_output_stream ();
  14. a.type (type ());
  15. write (out, that);
  16. a.read_value (out.create_input_stream (), type ());
  17. }
  18. public static org.omg.PortableServer.POAPackage.InvalidPolicy extract (org.omg.CORBA.Any a)
  19. {
  20. return read (a.create_input_stream ());
  21. }
  22. private static org.omg.CORBA.TypeCode __typeCode = null;
  23. private static boolean __active = false;
  24. synchronized public static org.omg.CORBA.TypeCode type ()
  25. {
  26. if (__typeCode == null)
  27. {
  28. synchronized (org.omg.CORBA.TypeCode.class)
  29. {
  30. if (__typeCode == null)
  31. {
  32. if (__active)
  33. {
  34. return org.omg.CORBA.ORB.init().create_recursive_tc ( _id );
  35. }
  36. __active = true;
  37. org.omg.CORBA.StructMember[] _members0 = new org.omg.CORBA.StructMember [1];
  38. org.omg.CORBA.TypeCode _tcOf_members0 = null;
  39. _tcOf_members0 = org.omg.CORBA.ORB.init ().get_primitive_tc (org.omg.CORBA.TCKind.tk_ushort);
  40. _members0[0] = new org.omg.CORBA.StructMember (
  41. "index",
  42. _tcOf_members0,
  43. null);
  44. __typeCode = org.omg.CORBA.ORB.init ().create_exception_tc (org.omg.PortableServer.POAPackage.InvalidPolicyHelper.id (), "InvalidPolicy", _members0);
  45. __active = false;
  46. }
  47. }
  48. }
  49. return __typeCode;
  50. }
  51. public static String id ()
  52. {
  53. return _id;
  54. }
  55. public static org.omg.PortableServer.POAPackage.InvalidPolicy read (org.omg.CORBA.portable.InputStream istream)
  56. {
  57. org.omg.PortableServer.POAPackage.InvalidPolicy value = new org.omg.PortableServer.POAPackage.InvalidPolicy ();
  58. // read and discard the repository ID
  59. istream.read_string ();
  60. value.index = istream.read_ushort ();
  61. return value;
  62. }
  63. public static void write (org.omg.CORBA.portable.OutputStream ostream, org.omg.PortableServer.POAPackage.InvalidPolicy value)
  64. {
  65. // write the repository ID
  66. ostream.write_string (id ());
  67. ostream.write_ushort (value.index);
  68. }
  69. }