edu.nps.moves.dismobile
Class GridAxisRecordRepresentation1

java.lang.Object
  extended by edu.nps.moves.dismobile.GridAxisRecord
      extended by edu.nps.moves.dismobile.GridAxisRecordRepresentation1
All Implemented Interfaces:
java.io.Serializable

public class GridAxisRecordRepresentation1
extends GridAxisRecord
implements java.io.Serializable

5.2.44: Grid data record, representation 1 Copyright (c) 2008-2010, MOVES Institute, Naval Postgraduate School. All rights reserved. This work is licensed under the BSD open source license, available at https://www.movesinstitute.org/licenses/bsd.html

Author:
DMcG
See Also:
Serialized Form

Field Summary
protected  java.util.List<TwoByteChunk> dataValues
          variable length list of data parameters ^^^this is wrong--need padding as well
protected  float fieldOffset
          constant offset used to scale grid data
protected  float fieldScale
          constant scale factor
protected  int numberOfValues
          Number of data values
 
Fields inherited from class edu.nps.moves.dismobile.GridAxisRecord
dataRepresentation, sampleType
 
Constructor Summary
GridAxisRecordRepresentation1()
          Constructor
 
Method Summary
 boolean equals(java.lang.Object obj)
           
 boolean equalsImpl(java.lang.Object obj)
          Compare all fields that contribute to the state, ignoring transient and static fields, for this and the supplied object
 java.util.List<TwoByteChunk> getDataValues()
           
 float getFieldOffset()
           
 float getFieldScale()
           
 int getMarshalledSize()
           
 int getNumberOfValues()
           
 void marshal(java.nio.ByteBuffer buff)
          Packs a Pdu into the ByteBuffer.
 void marshal(java.io.DataOutputStream dos)
           
 void setDataValues(java.util.List<TwoByteChunk> pDataValues)
           
 void setFieldOffset(float pFieldOffset)
           
 void setFieldScale(float pFieldScale)
           
 void setNumberOfValues(int pNumberOfValues)
          Note that setting this value will not change the marshalled value.
 void unmarshal(java.nio.ByteBuffer buff)
          Unpacks a Pdu from the underlying data.
 void unmarshal(java.io.DataInputStream dis)
           
 
Methods inherited from class edu.nps.moves.dismobile.GridAxisRecord
getDataRepresentation, getSampleType, setDataRepresentation, setSampleType
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

fieldScale

protected float fieldScale
constant scale factor


fieldOffset

protected float fieldOffset
constant offset used to scale grid data


numberOfValues

protected int numberOfValues
Number of data values


dataValues

protected java.util.List<TwoByteChunk> dataValues
variable length list of data parameters ^^^this is wrong--need padding as well

Constructor Detail

GridAxisRecordRepresentation1

public GridAxisRecordRepresentation1()
Constructor

Method Detail

getMarshalledSize

public int getMarshalledSize()
Overrides:
getMarshalledSize in class GridAxisRecord

setFieldScale

public void setFieldScale(float pFieldScale)

getFieldScale

public float getFieldScale()

setFieldOffset

public void setFieldOffset(float pFieldOffset)

getFieldOffset

public float getFieldOffset()

getNumberOfValues

public int getNumberOfValues()

setNumberOfValues

public void setNumberOfValues(int pNumberOfValues)
Note that setting this value will not change the marshalled value. The list whose length this describes is used for that purpose. The getnumberOfValues method will also be based on the actual list length rather than this value. The method is simply here for java bean completeness.


setDataValues

public void setDataValues(java.util.List<TwoByteChunk> pDataValues)

getDataValues

public java.util.List<TwoByteChunk> getDataValues()

marshal

public void marshal(java.io.DataOutputStream dos)
Overrides:
marshal in class GridAxisRecord

unmarshal

public void unmarshal(java.io.DataInputStream dis)
Overrides:
unmarshal in class GridAxisRecord

marshal

public void marshal(java.nio.ByteBuffer buff)
Packs a Pdu into the ByteBuffer.

Overrides:
marshal in class GridAxisRecord
Parameters:
buff - The ByteBuffer at the position to begin writing
Throws:
java.nio.BufferOverflowException - if buff is too small
java.nio.ReadOnlyBufferException - if buff is read only
Since:
??
See Also:
ByteBuffer

unmarshal

public void unmarshal(java.nio.ByteBuffer buff)
Unpacks a Pdu from the underlying data.

Overrides:
unmarshal in class GridAxisRecord
Parameters:
buff - The ByteBuffer at the position to begin reading
Throws:
java.nio.BufferUnderflowException - if buff is too small
Since:
??
See Also:
ByteBuffer

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class GridAxisRecord

equalsImpl

public boolean equalsImpl(java.lang.Object obj)
Description copied from class: GridAxisRecord
Compare all fields that contribute to the state, ignoring transient and static fields, for this and the supplied object

Overrides:
equalsImpl in class GridAxisRecord
Parameters:
obj - the object to compare to
Returns:
true if the objects are equal, false otherwise.