edu.nps.moves.dis7mobile
Class EntityDamageStatusPdu

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

public class EntityDamageStatusPdu
extends WarfareFamilyPdu
implements java.io.Serializable

shall be used to communicate detailed damage information sustained by an entity regardless of the source of the damage Section 7.3.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  EntityID damagedEntityID
          Field shall identify the damaged entity (see 6.2.28), Section 7.3.4 COMPLETE
protected  java.util.List<DirectedEnergyDamage> damageDescriptionRecords
          Fields shall contain one or more Damage Description records (see 6.2.17) and may contain other Standard Variable records, Section 7.3.5
protected  int numberOfDamageDescription
          field shall specify the number of Damage Description records, Section 7.3.5
protected  int padding1
          Padding.
protected  int padding2
          Padding.
 
Fields inherited from class edu.nps.moves.dis7mobile.WarfareFamilyPdu
firingEntityID, targetEntityID
 
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
EntityDamageStatusPdu()
          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
 EntityID getDamagedEntityID()
           
 java.util.List<DirectedEnergyDamage> getDamageDescriptionRecords()
           
 int getMarshalledSize()
           
 int getNumberOfDamageDescription()
           
 int getPadding1()
           
 int getPadding2()
           
 void marshal(java.nio.ByteBuffer buff)
          Packs a Pdu into the ByteBuffer.
 void marshal(java.io.DataOutputStream dos)
           
 void setDamagedEntityID(EntityID pDamagedEntityID)
           
 void setDamageDescriptionRecords(java.util.List<DirectedEnergyDamage> pDamageDescriptionRecords)
           
 void setNumberOfDamageDescription(int pNumberOfDamageDescription)
          Note that setting this value will not change the marshalled value.
 void setPadding1(int pPadding1)
           
 void setPadding2(int pPadding2)
           
 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.WarfareFamilyPdu
getFiringEntityID, getTargetEntityID, setFiringEntityID, setTargetEntityID
 
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

damagedEntityID

protected EntityID damagedEntityID
Field shall identify the damaged entity (see 6.2.28), Section 7.3.4 COMPLETE


padding1

protected int padding1
Padding.


padding2

protected int padding2
Padding.


numberOfDamageDescription

protected int numberOfDamageDescription
field shall specify the number of Damage Description records, Section 7.3.5


damageDescriptionRecords

protected java.util.List<DirectedEnergyDamage> damageDescriptionRecords
Fields shall contain one or more Damage Description records (see 6.2.17) and may contain other Standard Variable records, Section 7.3.5

Constructor Detail

EntityDamageStatusPdu

public EntityDamageStatusPdu()
Constructor

Method Detail

getMarshalledSize

public int getMarshalledSize()
Overrides:
getMarshalledSize in class WarfareFamilyPdu

setDamagedEntityID

public void setDamagedEntityID(EntityID pDamagedEntityID)

getDamagedEntityID

public EntityID getDamagedEntityID()

setPadding1

public void setPadding1(int pPadding1)

getPadding1

public int getPadding1()

setPadding2

public void setPadding2(int pPadding2)

getPadding2

public int getPadding2()

getNumberOfDamageDescription

public int getNumberOfDamageDescription()

setNumberOfDamageDescription

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


setDamageDescriptionRecords

public void setDamageDescriptionRecords(java.util.List<DirectedEnergyDamage> pDamageDescriptionRecords)

getDamageDescriptionRecords

public java.util.List<DirectedEnergyDamage> getDamageDescriptionRecords()

marshal

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

unmarshal

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

marshal

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

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

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 WarfareFamilyPdu
Parameters:
obj - the object to compare to
Returns:
true if the objects are equal, false otherwise.