Class DirectedEnergyDamage
java.lang.Object
edu.nps.moves.dis7.pdus.DirectedEnergyDamage
- All Implemented Interfaces:
Serializable
Damage sustained by an entity due to directed energy. Location of the damage based on a relative x,y,z location from the center of the entity. Section 6.2.15.2
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected DEDamageDescriptionComponentDamageStatus
enumeration uid 315enumeration uid 314enumeration uid 317enumeration uid 316protected float
Size of damaged area, in metersprotected Vector3Float
location of damage, relative to center of entityprotected EventIdentifier
For any component damage resulting this field shall be set to the fire event ID from that PDU.protected short
zero-filled array of padding bits for byte alignment and consistent sizing of PDU dataprotected short
paddingprotected short
DE Record Length (bytes)protected int
DE Record Type.protected float
average temp of the damaged area, in degrees celsius. -
Constructor Summary
ConstructorsConstructorDescriptionConstructor creates and configures a new instance object -
Method Summary
Modifier and TypeMethodDescriptionboolean
boolean
equalsImpl
(Object obj) Compare all fields that contribute to the state, ignoring transient and static fields, forthis
and the supplied objectGetter forcomponentDamageStatus
Getter forcomponentIdentification
Getter forcomponentVisualDamageStatus
Getter forcomponentVisualSmokeColor
float
Getter fordamageDiameter
Getter fordamageLocation
Getter forfireEventID
int
Returns size of this serialized (marshalled) object in bytesshort
Getter forpadding
short
Getter forpadding2
short
Getter forrecordLength
int
Getter forrecordType
float
Getter fortemperature
int
hashCode()
void
marshal
(DataOutputStream dos) Serializes an object to a DataOutputStream.void
marshal
(ByteBuffer byteBuffer) Packs an object into the ByteBuffer.setComponentDamageStatus
(DEDamageDescriptionComponentDamageStatus pComponentDamageStatus) Setter forcomponentDamageStatus
setComponentIdentification
(EntityDamageStatusComponentIdentification pComponentIdentification) Setter forcomponentIdentification
setComponentVisualDamageStatus
(DEDamageDescriptionComponentVisualDamageStatus pComponentVisualDamageStatus) Setter forcomponentVisualDamageStatus
setComponentVisualSmokeColor
(DEDamageDescriptionComponentVisualSmokeColor pComponentVisualSmokeColor) Setter forcomponentVisualSmokeColor
setDamageDiameter
(float pDamageDiameter) Setter fordamageDiameter
setDamageLocation
(Vector3Float pDamageLocation) Setter fordamageLocation
setFireEventID
(EventIdentifier pFireEventID) Setter forfireEventID
setPadding
(int pPadding) Utility setter forpadding
setPadding
(short pPadding) Setter forpadding
setPadding2
(int pPadding2) Utility setter forpadding2
setPadding2
(short pPadding2) Setter forpadding2
setRecordLength
(int pRecordLength) Utility setter forrecordLength
setRecordLength
(short pRecordLength) Setter forrecordLength
setRecordType
(int pRecordType) Setter forrecordType
setTemperature
(float pTemperature) Setter fortemperature
toString()
int
unmarshal
(DataInputStream dis) Deserializes an object from a DataInputStream.int
unmarshal
(ByteBuffer byteBuffer) Unpacks a Pdu from the underlying data.
-
Field Details
-
recordType
protected int recordTypeDE Record Type. -
recordLength
protected short recordLengthDE Record Length (bytes) -
padding
protected short paddingzero-filled array of padding bits for byte alignment and consistent sizing of PDU data -
damageLocation
location of damage, relative to center of entity -
damageDiameter
protected float damageDiameterSize of damaged area, in meters -
temperature
protected float temperatureaverage temp of the damaged area, in degrees celsius. If firing entitty does not model this, use a value of -273.15 -
componentIdentification
enumeration uid 314 -
componentDamageStatus
enumeration uid 315 -
componentVisualDamageStatus
enumeration uid 317 -
componentVisualSmokeColor
enumeration uid 316 -
fireEventID
For any component damage resulting this field shall be set to the fire event ID from that PDU. -
padding2
protected short padding2padding
-
-
Constructor Details
-
DirectedEnergyDamage
public DirectedEnergyDamage()Constructor creates and configures a new instance object
-
-
Method Details
-
getMarshalledSize
public int getMarshalledSize()Returns size of this serialized (marshalled) object in bytes- Returns:
- serialized size in bytes
- See Also:
-
setRecordType
Setter forrecordType
- Parameters:
pRecordType
- new value of interest- Returns:
- same object to permit progressive setters
-
getRecordType
-
setRecordLength
Setter forrecordLength
- Parameters:
pRecordLength
- new value of interest- Returns:
- same object to permit progressive setters
-
setRecordLength
Utility setter forrecordLength
- Parameters:
pRecordLength
- new value of interest- Returns:
- same object to permit progressive setters
-
getRecordLength
-
setPadding
Setter forpadding
- Parameters:
pPadding
- new value of interest- Returns:
- same object to permit progressive setters
-
setPadding
Utility setter forpadding
- Parameters:
pPadding
- new value of interest- Returns:
- same object to permit progressive setters
-
getPadding
-
setDamageLocation
Setter fordamageLocation
- Parameters:
pDamageLocation
- new value of interest- Returns:
- same object to permit progressive setters
-
getDamageLocation
-
setDamageDiameter
Setter fordamageDiameter
- Parameters:
pDamageDiameter
- new value of interest- Returns:
- same object to permit progressive setters
-
getDamageDiameter
-
setTemperature
Setter fortemperature
- Parameters:
pTemperature
- new value of interest- Returns:
- same object to permit progressive setters
-
getTemperature
-
setComponentIdentification
public DirectedEnergyDamage setComponentIdentification(EntityDamageStatusComponentIdentification pComponentIdentification) Setter forcomponentIdentification
- Parameters:
pComponentIdentification
- new value of interest- Returns:
- same object to permit progressive setters
-
getComponentIdentification
Getter forcomponentIdentification
- Returns:
- value of interest
-
setComponentDamageStatus
public DirectedEnergyDamage setComponentDamageStatus(DEDamageDescriptionComponentDamageStatus pComponentDamageStatus) Setter forcomponentDamageStatus
- Parameters:
pComponentDamageStatus
- new value of interest- Returns:
- same object to permit progressive setters
-
getComponentDamageStatus
Getter forcomponentDamageStatus
- Returns:
- value of interest
-
setComponentVisualDamageStatus
public DirectedEnergyDamage setComponentVisualDamageStatus(DEDamageDescriptionComponentVisualDamageStatus pComponentVisualDamageStatus) Setter forcomponentVisualDamageStatus
- Parameters:
pComponentVisualDamageStatus
- new value of interest- Returns:
- same object to permit progressive setters
-
getComponentVisualDamageStatus
Getter forcomponentVisualDamageStatus
- Returns:
- value of interest
-
setComponentVisualSmokeColor
public DirectedEnergyDamage setComponentVisualSmokeColor(DEDamageDescriptionComponentVisualSmokeColor pComponentVisualSmokeColor) Setter forcomponentVisualSmokeColor
- Parameters:
pComponentVisualSmokeColor
- new value of interest- Returns:
- same object to permit progressive setters
-
getComponentVisualSmokeColor
Getter forcomponentVisualSmokeColor
- Returns:
- value of interest
-
setFireEventID
Setter forfireEventID
- Parameters:
pFireEventID
- new value of interest- Returns:
- same object to permit progressive setters
-
getFireEventID
-
setPadding2
Setter forpadding2
- Parameters:
pPadding2
- new value of interest- Returns:
- same object to permit progressive setters
-
setPadding2
Utility setter forpadding2
- Parameters:
pPadding2
- new value of interest- Returns:
- same object to permit progressive setters
-
getPadding2
-
marshal
Serializes an object to a DataOutputStream.- Parameters:
dos
- the OutputStream- Throws:
Exception
- if something goes wrong- See Also:
-
unmarshal
Deserializes an object from a DataInputStream.- Parameters:
dis
- the InputStream- Returns:
- marshalled serialized size in bytes
- Throws:
Exception
- if something goes wrong- See Also:
-
marshal
Packs an object into the ByteBuffer.- Parameters:
byteBuffer
- The ByteBuffer at the position to begin writing- Throws:
BufferOverflowException
- if byteBuffer is too smallReadOnlyBufferException
- if byteBuffer is read onlyException
- ByteBuffer-generated exception- See Also:
-
unmarshal
Unpacks a Pdu from the underlying data.- Parameters:
byteBuffer
- The ByteBuffer at the position to begin reading- Returns:
- marshalled serialized size in bytes
- Throws:
BufferUnderflowException
- if byteBuffer is too smallException
- ByteBuffer-generated exception- See Also:
-
equals
-
equalsImpl
Compare all fields that contribute to the state, ignoring transient and static fields, forthis
and the supplied object- Parameters:
obj
- the object to compare to- Returns:
- true if the objects are equal, false otherwise.
-
toString
-
hashCode
-