package nomadgui.Telemetry;

import distinct.rpc.*;

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

public class imuRawState implements XDRType {
  public int[] rotDotVolts = new int[3];
  public int[] transDotDotVolts = new int[3];
  public int tempVolts;
  public int msecs;
  public int week;

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

public imuRawState()
{}

/**
 * Creates an object of class imuRawState.
 * @param     arg_rotDotVolts The value of the rotDotVolts component.
 * @param     arg_transDotDotVolts The value of the transDotDotVolts component.
 * @param     arg_tempVolts The value of the tempVolts component.
 * @param     arg_msecs The value of the msecs component.
 * @param     arg_week The value of the week component.
 */

public imuRawState(int[] arg_rotDotVolts, int[] arg_transDotDotVolts, int arg_tempVolts, int arg_msecs, int arg_week)
{
  rotDotVolts = arg_rotDotVolts;
  transDotDotVolts = arg_transDotDotVolts;
  tempVolts = arg_tempVolts;
  msecs = arg_msecs;
  week = arg_week;
}

/**
 * Encodes an object of class imuRawState 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 < 3; i_v++){
    xdrs.xdr_encode_int(rotDotVolts[i_v]);
  }
  for (int i_v = 0; i_v < 3; i_v++){
    xdrs.xdr_encode_int(transDotDotVolts[i_v]);
  }
  xdrs.xdr_encode_int(tempVolts);
  xdrs.xdr_encode_int(msecs);
  xdrs.xdr_encode_int(week);
}

/**
 * Decodes an object of class imuRawState 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
{
  rotDotVolts = new int[3];
  for (int i_v = 0; i_v < 3; i_v++){
    rotDotVolts[i_v] = xdrs.xdr_decode_int();
  }
  transDotDotVolts = new int[3];
  for (int i_v = 0; i_v < 3; i_v++){
    transDotDotVolts[i_v] = xdrs.xdr_decode_int();
  }
  tempVolts = xdrs.xdr_decode_int();
  msecs = xdrs.xdr_decode_int();
  week = xdrs.xdr_decode_int();
}
}
