package nomadgui.Telemetry;

import distinct.rpc.*;

/**
 * This class was automatically generated by Jrpcgen from the RPC/XDR file "morInternalState.x".<br>
 * morInternalState: was struct
 */

public class morInternalState implements XDRType {
  public float[] morphinSteer = new float[2];
  public int msecs;
  public int week;

/**
 * Default constructor for objects of class morInternalState.
 */

public morInternalState()
{}

/**
 * Creates an object of class morInternalState.
 * @param     arg_morphinSteer The value of the morphinSteer component.
 * @param     arg_msecs The value of the msecs component.
 * @param     arg_week The value of the week component.
 */

public morInternalState(float[] arg_morphinSteer, int arg_msecs, int arg_week)
{
  morphinSteer = arg_morphinSteer;
  msecs = arg_msecs;
  week = arg_week;
}

/**
 * Encodes an object of class morInternalState in compliance to RFC 1832 (XDR).
 * @param     xdrs The XDR output stream.
 */

public void xdr_encode(XDRStream xdrs)
{
  for (int i_v = 0; i_v < 2; i_v++){
    xdrs.xdr_encode_float(morphinSteer[i_v]);
  }
  xdrs.xdr_encode_int(msecs);
  xdrs.xdr_encode_int(week);
}

/**
 * Decodes an object of class morInternalState in compliance to RFC 1832 (XDR).
 * @param     xdrs The XDR input stream.
 * @exception RPCError When the calls fails for any reason.
 */

public void xdr_decode(XDRStream xdrs) throws RPCError
{
  morphinSteer = new float[2];
  for (int i_v = 0; i_v < 2; i_v++){
    morphinSteer[i_v] = xdrs.xdr_decode_float();
  }
  msecs = xdrs.xdr_decode_int();
  week = xdrs.xdr_decode_int();
}
}
