1. /*
  2. * @(#)VersionSpecHelper.java 1.8 03/01/23
  3. *
  4. * Copyright 2003 Sun Microsystems, Inc. All rights reserved.
  5. * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
  6. */
  7. package org.omg.CORBA;
  8. /**
  9. * The Helper for <tt>VersionSpec</tt>. For more information on
  10. * Helper files, see <a href="doc-files/generatedfiles.html#helper">
  11. * "Generated Files: Helper Files"</a>.<P>
  12. * org/omg/CORBA/VersionSpecHelper.java
  13. * Generated by the IDL-to-Java compiler (portable), version "3.0"
  14. * from ir.idl
  15. * 03 June 1999 11:33:43 o'clock GMT+00:00
  16. */
  17. abstract public class VersionSpecHelper
  18. {
  19. private static String _id = "IDL:omg.org/CORBA/VersionSpec:1.0";
  20. public static void insert (org.omg.CORBA.Any a, String that)
  21. {
  22. org.omg.CORBA.portable.OutputStream out = a.create_output_stream ();
  23. a.type (type ());
  24. write (out, that);
  25. a.read_value (out.create_input_stream (), type ());
  26. }
  27. public static String extract (org.omg.CORBA.Any a)
  28. {
  29. return read (a.create_input_stream ());
  30. }
  31. private static org.omg.CORBA.TypeCode __typeCode = null;
  32. synchronized public static org.omg.CORBA.TypeCode type ()
  33. {
  34. if (__typeCode == null)
  35. {
  36. __typeCode = org.omg.CORBA.ORB.init ().create_string_tc (0);
  37. __typeCode = org.omg.CORBA.ORB.init ().create_alias_tc (org.omg.CORBA.VersionSpecHelper.id (), "VersionSpec", __typeCode);
  38. }
  39. return __typeCode;
  40. }
  41. public static String id ()
  42. {
  43. return _id;
  44. }
  45. public static String read (org.omg.CORBA.portable.InputStream istream)
  46. {
  47. String value = null;
  48. value = istream.read_string ();
  49. return value;
  50. }
  51. public static void write (org.omg.CORBA.portable.OutputStream ostream, String value)
  52. {
  53. ostream.write_string (value);
  54. }
  55. }