edu.nps.moves.dis7mobile
Class EntityStateUpdatePdu

java.lang.Object
  extended by edu.nps.moves.dis7mobile.PduSuperclass
      extended by edu.nps.moves.dis7mobile.Pdu
          extended by edu.nps.moves.dis7mobile.EntityInformationFamilyPdu
              extended by edu.nps.moves.dis7mobile.EntityStateUpdatePdu
All Implemented Interfaces:
java.io.Serializable

public class EntityStateUpdatePdu
extends EntityInformationFamilyPdu
implements java.io.Serializable

Nonstatic information about a particular entity may be communicated by issuing an Entity State Update PDU. Section 7.2.5. COMPLETE 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  long entityAppearance
          This field shall specify the dynamic changes to the entitys appearance attributes.
protected  EntityID entityID
          This field shall identify the entity issuing the PDU, and shall be represented by an Entity Identifier record (see 6.2.28).
protected  Vector3Float entityLinearVelocity
          This field shall specify an entitys linear velocity.
protected  Vector3Double entityLocation
          This field shall specify an entitys physical location in the simulated world and shall be represented by a World Coordinates record (see 6.2.97).
protected  EulerAngles entityOrientation
          This field shall specify an entitys orientation and shall be represented by an Euler Angles record (see 6.2.33).
protected  short numberOfVariableParameters
          This field shall specify the number of variable parameters present.
protected  byte padding1
          Padding
protected  java.util.List<VariableParameter> variableParameters
          This field shall specify the parameter values for each Variable Parameter record that is included (see 6.2.93 and Annex I).
 
Fields inherited from class edu.nps.moves.dis7mobile.Pdu
padding, pduStatus
 
Fields inherited from class edu.nps.moves.dis7mobile.PduSuperclass
exerciseID, length, pduType, protocolFamily, protocolVersion, timestamp
 
Constructor Summary
EntityStateUpdatePdu()
          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
 long getEntityAppearance()
           
 EntityID getEntityID()
           
 Vector3Float getEntityLinearVelocity()
           
 Vector3Double getEntityLocation()
           
 EulerAngles getEntityOrientation()
           
 int getMarshalledSize()
           
 short getNumberOfVariableParameters()
           
 byte getPadding1()
           
 java.util.List<VariableParameter> getVariableParameters()
           
 void marshal(java.nio.ByteBuffer buff)
          Packs a Pdu into the ByteBuffer.
 void marshal(java.io.DataOutputStream dos)
           
 void setEntityAppearance(long pEntityAppearance)
           
 void setEntityID(EntityID pEntityID)
           
 void setEntityLinearVelocity(Vector3Float pEntityLinearVelocity)
           
 void setEntityLocation(Vector3Double pEntityLocation)
           
 void setEntityOrientation(EulerAngles pEntityOrientation)
           
 void setNumberOfVariableParameters(short pNumberOfVariableParameters)
          Note that setting this value will not change the marshalled value.
 void setPadding1(byte pPadding1)
           
 void setVariableParameters(java.util.List<VariableParameter> pVariableParameters)
           
 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.dis7mobile.Pdu
getPadding, getPduStatus, marshal, setPadding, setPduStatus
 
Methods inherited from class edu.nps.moves.dis7mobile.PduSuperclass
getExerciseID, getLength, getPduType, getProtocolFamily, getProtocolVersion, getTimestamp, setExerciseID, setLength, setPduType, setProtocolFamily, setProtocolVersion, setTimestamp
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

entityID

protected EntityID entityID
This field shall identify the entity issuing the PDU, and shall be represented by an Entity Identifier record (see 6.2.28).


padding1

protected byte padding1
Padding


numberOfVariableParameters

protected short numberOfVariableParameters
This field shall specify the number of variable parameters present. This field shall be represented by an 8-bit unsigned integer (see Annex I).


entityLinearVelocity

protected Vector3Float entityLinearVelocity
This field shall specify an entitys linear velocity. The coordinate system for an entitys linear velocity depends on the dead reckoning algorithm used. This field shall be represented by a Linear Velocity Vector record [see 6.2.95 item c)]).


entityLocation

protected Vector3Double entityLocation
This field shall specify an entitys physical location in the simulated world and shall be represented by a World Coordinates record (see 6.2.97).


entityOrientation

protected EulerAngles entityOrientation
This field shall specify an entitys orientation and shall be represented by an Euler Angles record (see 6.2.33).


entityAppearance

protected long entityAppearance
This field shall specify the dynamic changes to the entitys appearance attributes. This field shall be represented by an Entity Appearance record (see 6.2.26).


variableParameters

protected java.util.List<VariableParameter> variableParameters
This field shall specify the parameter values for each Variable Parameter record that is included (see 6.2.93 and Annex I).

Constructor Detail

EntityStateUpdatePdu

public EntityStateUpdatePdu()
Constructor

Method Detail

getMarshalledSize

public int getMarshalledSize()
Overrides:
getMarshalledSize in class EntityInformationFamilyPdu

setEntityID

public void setEntityID(EntityID pEntityID)

getEntityID

public EntityID getEntityID()

setPadding1

public void setPadding1(byte pPadding1)

getPadding1

public byte getPadding1()

getNumberOfVariableParameters

public short getNumberOfVariableParameters()

setNumberOfVariableParameters

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


setEntityLinearVelocity

public void setEntityLinearVelocity(Vector3Float pEntityLinearVelocity)

getEntityLinearVelocity

public Vector3Float getEntityLinearVelocity()

setEntityLocation

public void setEntityLocation(Vector3Double pEntityLocation)

getEntityLocation

public Vector3Double getEntityLocation()

setEntityOrientation

public void setEntityOrientation(EulerAngles pEntityOrientation)

getEntityOrientation

public EulerAngles getEntityOrientation()

setEntityAppearance

public void setEntityAppearance(long pEntityAppearance)

getEntityAppearance

public long getEntityAppearance()

setVariableParameters

public void setVariableParameters(java.util.List<VariableParameter> pVariableParameters)

getVariableParameters

public java.util.List<VariableParameter> getVariableParameters()

marshal

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

unmarshal

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

marshal

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

Overrides:
marshal in class EntityInformationFamilyPdu
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 EntityInformationFamilyPdu
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 EntityInformationFamilyPdu

equalsImpl

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

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