/*
 * File: ./REMOTEINTERFACE/CURRENTSTATEHELPER.JAVA
 * From: REMOTE.IDL
 * Date: Thu Jan 21 23:55:04 1999
 *   By: C:\JDK1.2\BIN\IDLTOJ~1.EXE Java IDL 1.2 Nov 10 1997 13:52:11
 */

package RemoteInterface;
public class CurrentStateHelper {
     // It is useless to have instances of this class
     private CurrentStateHelper() { }

    public static void write(org.omg.CORBA.portable.OutputStream out, int[] that)  {
          {
              if (that.length > (9L)) {
                  throw new org.omg.CORBA.MARSHAL(0, org.omg.CORBA.CompletionStatus.COMPLETED_MAYBE);
              }
              out.write_long(that.length);
              out.write_long_array(that, 0, that.length);
          }
    }
    public static int[] read(org.omg.CORBA.portable.InputStream in) {
          int[] that;
          {
              int __length = in.read_long();
              if (__length > (9L)) {
                  throw new org.omg.CORBA.MARSHAL(0, org.omg.CORBA.CompletionStatus.COMPLETED_MAYBE);
              }
              that = new int[__length];
              in.read_long_array(that, 0, that.length);
          }
          return that;
    }
   public static int[] extract(org.omg.CORBA.Any a) {
     org.omg.CORBA.portable.InputStream in = a.create_input_stream();
     return read(in);
   }
   public static void insert(org.omg.CORBA.Any a, int[] that) {
     org.omg.CORBA.portable.OutputStream out = a.create_output_stream();
     a.type(type());
     write(out, that);
     a.read_value(out.create_input_stream(), type());
   }
   private static org.omg.CORBA.TypeCode _tc;
   synchronized public static org.omg.CORBA.TypeCode type() {
          if (_tc == null)
             _tc = org.omg.CORBA.ORB.init().create_alias_tc(id(), "CurrentState", org.omg.CORBA.ORB.init().create_sequence_tc((int) (9L), org.omg.CORBA.ORB.init().get_primitive_tc(org.omg.CORBA.TCKind.tk_long)));
      return _tc;
   }
   public static String id() {
       return "IDL:RemoteInterface/CurrentState:1.0";
   }
}
