Package edu.nps.moves.dis7
Class AggregateStatePdu
java.lang.Object
edu.nps.moves.dis7.Pdu
edu.nps.moves.dis7.PduBase
edu.nps.moves.dis7.EntityManagementFamilyPdu
edu.nps.moves.dis7.AggregateStatePdu
- All Implemented Interfaces:
edu.nps.moves.dis7.Marshaller
,java.io.Serializable
public class AggregateStatePdu extends EntityManagementFamilyPdu implements java.io.Serializable
5.9.2.2 The Aggregate State PDU shall be used to communicate the state and other pertinent information about an aggregated unit.
IEEE Std 1278.1-2012, IEEE Standard for Distributed Interactive Simulation—Application Protocols
- See Also:
- Serialized Form
-
Field Summary
Fields Modifier and Type Field Description protected AggregateIdentifier
aggregateID
ID of aggregated entitiesprotected java.util.List<AggregateIdentifier>
aggregateIDList
aggregates listprotected AggregateMarking
aggregateMarking
marking for aggregate; first char is charset type, rest is char dataprotected AggregateStateAggregateState
aggregateState
state of aggregate uid 204protected AggregateType
aggregateType
entity type of the aggregated entitiesprotected Vector3Double
centerOfMass
center of mass of the aggregationprotected Vector3Float
dimensions
dimensions of bounding box for the aggregated entities, origin at the center of massprotected java.util.List<EntityID>
entityIDList
entity ID listprotected ForceID
forceID
force ID uid 6protected AggregateStateFormation
formation
formation of aggregated entities uid 205protected short
numberOfDisAggregates
number of aggregatesprotected short
numberOfDisEntities
number of entitiesprotected short
numberOfSilentAggregateTypes
number of silent aggregate typesprotected short
numberOfSilentEntityTypes
Number of silent entity types, handled automatically by marshaller at run time (and not modifiable by end-user programmers)protected int
numberOfVariableDatumRecords
Number of variable datum records, handled automatically by marshaller at run time (and not modifiable by end-user programmers)protected Vector3Float
orientation
orientation of the bounding boxprotected java.util.List<EntityType>
silentAggregateSystemList
silent entity typesprotected java.util.List<EntityType>
silentEntitySystemList
silent entity typesprotected java.util.List<edu.nps.moves.dis7.VariableDatum>
variableDatumList
variableDatumsprotected Vector3Float
velocity
velocity of aggregationFields inherited from class edu.nps.moves.dis7.Pdu
exerciseID, length, pduType, protocolFamily, protocolVersion, timestamp
-
Constructor Summary
Constructors Constructor Description AggregateStatePdu()
Constructor -
Method Summary
Methods inherited from class edu.nps.moves.dis7.PduBase
getPadding, getPduStatus, setPadding, setPduStatus
Methods inherited from class edu.nps.moves.dis7.Pdu
getExerciseID, getLength, getPduType, getProtocolFamily, getProtocolVersion, getTimestamp, marshal, setExerciseID, setLength, setPduType, setProtocolFamily, setProtocolVersion, setTimestamp
-
Field Details
-
aggregateID
ID of aggregated entities -
forceID
force ID uid 6 -
aggregateState
state of aggregate uid 204 -
aggregateType
entity type of the aggregated entities -
formation
formation of aggregated entities uid 205 -
aggregateMarking
marking for aggregate; first char is charset type, rest is char data -
dimensions
dimensions of bounding box for the aggregated entities, origin at the center of mass -
orientation
orientation of the bounding box -
centerOfMass
center of mass of the aggregation -
velocity
velocity of aggregation -
numberOfDisAggregates
protected short numberOfDisAggregatesnumber of aggregates -
numberOfDisEntities
protected short numberOfDisEntitiesnumber of entities -
numberOfSilentAggregateTypes
protected short numberOfSilentAggregateTypesnumber of silent aggregate types -
numberOfSilentEntityTypes
protected short numberOfSilentEntityTypesNumber of silent entity types, handled automatically by marshaller at run time (and not modifiable by end-user programmers) -
aggregateIDList
aggregates list -
entityIDList
entity ID list -
silentAggregateSystemList
silent entity types -
silentEntitySystemList
silent entity types -
numberOfVariableDatumRecords
protected int numberOfVariableDatumRecordsNumber of variable datum records, handled automatically by marshaller at run time (and not modifiable by end-user programmers) -
variableDatumList
protected java.util.List<edu.nps.moves.dis7.VariableDatum> variableDatumListvariableDatums
-
-
Constructor Details
-
AggregateStatePdu
public AggregateStatePdu()Constructor
-
-
Method Details
-
getMarshalledSize
public int getMarshalledSize()Returns the size of this serialized object in bytes- Specified by:
getMarshalledSize
in interfaceedu.nps.moves.dis7.Marshaller
- Overrides:
getMarshalledSize
in classEntityManagementFamilyPdu
-
setAggregateID
Setter foraggregateID
-
getAggregateID
Getter foraggregateID
-
setForceID
Setter forforceID
-
getForceID
Getter forforceID
-
setAggregateState
Setter foraggregateState
-
getAggregateState
Getter foraggregateState
-
setAggregateType
Setter foraggregateType
-
getAggregateType
Getter foraggregateType
-
setFormation
Setter forformation
-
getFormation
Getter forformation
-
setAggregateMarking
Setter foraggregateMarking
-
getAggregateMarking
Getter foraggregateMarking
-
setDimensions
Setter fordimensions
-
getDimensions
Getter fordimensions
-
setOrientation
Setter fororientation
-
getOrientation
Getter fororientation
-
setCenterOfMass
Setter forcenterOfMass
-
getCenterOfMass
Getter forcenterOfMass
-
setVelocity
Setter forvelocity
-
getVelocity
Getter forvelocity
-
setAggregateIDList
Setter foraggregateIDList
-
getAggregateIDList
Getter foraggregateIDList
-
setEntityIDList
Setter forentityIDList
-
getEntityIDList
Getter forentityIDList
-
setSilentAggregateSystemList
public AggregateStatePdu setSilentAggregateSystemList(java.util.List<EntityType> pSilentAggregateSystemList)Setter forsilentAggregateSystemList
-
getSilentAggregateSystemList
Getter forsilentAggregateSystemList
-
setSilentEntitySystemList
public AggregateStatePdu setSilentEntitySystemList(java.util.List<EntityType> pSilentEntitySystemList)Setter forsilentEntitySystemList
-
getSilentEntitySystemList
Getter forsilentEntitySystemList
-
setVariableDatumList
public AggregateStatePdu setVariableDatumList(java.util.List<edu.nps.moves.dis7.VariableDatum> pVariableDatumList)Setter forvariableDatumList
-
getVariableDatumList
public java.util.List<edu.nps.moves.dis7.VariableDatum> getVariableDatumList()Getter forvariableDatumList
-
marshal
public void marshal(java.io.DataOutputStream dos) throws java.lang.ExceptionSerializes an object to a DataOutputStream.- Specified by:
marshal
in interfaceedu.nps.moves.dis7.Marshaller
- Overrides:
marshal
in classEntityManagementFamilyPdu
- Parameters:
dos
- the OutputStream- Throws:
java.lang.Exception
- if something goes wrong- See Also:
DataOutputStream
-
unmarshal
public int unmarshal(java.io.DataInputStream dis) throws java.lang.ExceptionUnserializes an object from a DataInputStream.- Specified by:
unmarshal
in interfaceedu.nps.moves.dis7.Marshaller
- Overrides:
unmarshal
in classEntityManagementFamilyPdu
- Parameters:
dis
- the InputStream- Returns:
- unmarshalled size
- Throws:
java.lang.Exception
- if something goes wrong- See Also:
DataInputStream
-
marshal
public void marshal(java.nio.ByteBuffer buff) throws java.lang.ExceptionPacks an object into the ByteBuffer.- Specified by:
marshal
in interfaceedu.nps.moves.dis7.Marshaller
- Overrides:
marshal
in classEntityManagementFamilyPdu
- Parameters:
buff
- The ByteBuffer at the position to begin writing- Throws:
java.nio.BufferOverflowException
- if buff is too smalljava.nio.ReadOnlyBufferException
- if buff is read onlyjava.lang.Exception
- ByteBuffer-generated exception- See Also:
ByteBuffer
-
unmarshal
public int unmarshal(java.nio.ByteBuffer buff) throws java.lang.ExceptionUnpacks a Pdu from the underlying data.- Specified by:
unmarshal
in interfaceedu.nps.moves.dis7.Marshaller
- Overrides:
unmarshal
in classEntityManagementFamilyPdu
- Parameters:
buff
- The ByteBuffer at the position to begin reading- Returns:
- marshalled size
- Throws:
java.nio.BufferUnderflowException
- if buff is too smalljava.lang.Exception
- ByteBuffer-generated exception- See Also:
ByteBuffer
-
equals
public boolean equals(java.lang.Object obj)- Overrides:
equals
in classEntityManagementFamilyPdu
-
equalsImpl
public boolean equalsImpl(java.lang.Object obj)Description copied from class:Pdu
Compare all fields that contribute to the state, ignoring transient and static fields, forthis
and the supplied object- Overrides:
equalsImpl
in classEntityManagementFamilyPdu
- Parameters:
obj
- the object to compare to- Returns:
- true if the objects are equal, false otherwise.
-
toString
public java.lang.String toString()- Overrides:
toString
in classEntityManagementFamilyPdu
-