edu.nps.moves.dismobile
Class FirePdu

java.lang.Object
  extended by edu.nps.moves.dismobile.Pdu
      extended by edu.nps.moves.dismobile.WarfareFamilyPdu
          extended by edu.nps.moves.dismobile.FirePdu
All Implemented Interfaces:
java.io.Serializable

public class FirePdu
extends WarfareFamilyPdu
implements java.io.Serializable

Sectioin 5.3.4.1. Information about someone firing something. 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  BurstDescriptor burstDescriptor
          Describes munitions used in the firing event
protected  EventID eventID
          ID of event
protected  int fireMissionIndex
           
protected  Vector3Double locationInWorldCoordinates
          location of the firing event
protected  EntityID munitionID
          ID of the munition that is being shot
protected  float rangeToTarget
          range to the target.
protected  Vector3Float velocity
          Velocity of the ammunition
 
Fields inherited from class edu.nps.moves.dismobile.WarfareFamilyPdu
firingEntityID, targetEntityID
 
Fields inherited from class edu.nps.moves.dismobile.Pdu
exerciseID, padding, pduLength, pduType, protocolFamily, protocolVersion, timestamp
 
Constructor Summary
FirePdu()
          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
 BurstDescriptor getBurstDescriptor()
           
 EventID getEventID()
           
 int getFireMissionIndex()
           
 Vector3Double getLocationInWorldCoordinates()
           
 int getMarshalledSize()
           
 EntityID getMunitionID()
           
 float getRangeToTarget()
           
 Vector3Float getVelocity()
           
 void marshal(java.nio.ByteBuffer buff)
          Packs a Pdu into the ByteBuffer.
 void marshal(java.io.DataOutputStream dos)
           
 void setBurstDescriptor(BurstDescriptor pBurstDescriptor)
           
 void setEventID(EventID pEventID)
           
 void setFireMissionIndex(int pFireMissionIndex)
           
 void setLocationInWorldCoordinates(Vector3Double pLocationInWorldCoordinates)
           
 void setMunitionID(EntityID pMunitionID)
           
 void setRangeToTarget(float pRangeToTarget)
           
 void setVelocity(Vector3Float pVelocity)
           
 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.WarfareFamilyPdu
getFiringEntityID, getTargetEntityID, setFiringEntityID, setTargetEntityID
 
Methods inherited from class edu.nps.moves.dismobile.Pdu
getExerciseID, getLength, getPadding, getPduLength, getPduType, getProtocolFamily, getProtocolVersion, getTimestamp, marshal, marshalWithDisAbsoluteTimestamp, marshalWithDisAbsoluteTimestamp, marshalWithDisRelativeTimestamp, marshalWithDisRelativeTimestamp, marshalWithNpsTimestamp, marshalWithNpsTimestamp, marshalWithUnixTimestamp, marshalWithUnixTimestamp, readUnsignedInt, readUnsignedInt, setExerciseID, setPadding, setPduLength, setPduType, setProtocolFamily, setProtocolVersion, setTimestamp
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

munitionID

protected EntityID munitionID
ID of the munition that is being shot


eventID

protected EventID eventID
ID of event


fireMissionIndex

protected int fireMissionIndex

locationInWorldCoordinates

protected Vector3Double locationInWorldCoordinates
location of the firing event


burstDescriptor

protected BurstDescriptor burstDescriptor
Describes munitions used in the firing event


velocity

protected Vector3Float velocity
Velocity of the ammunition


rangeToTarget

protected float rangeToTarget
range to the target. Note the word range is a SQL reserved word.

Constructor Detail

FirePdu

public FirePdu()
Constructor

Method Detail

getMarshalledSize

public int getMarshalledSize()
Overrides:
getMarshalledSize in class WarfareFamilyPdu

setMunitionID

public void setMunitionID(EntityID pMunitionID)

getMunitionID

public EntityID getMunitionID()

setEventID

public void setEventID(EventID pEventID)

getEventID

public EventID getEventID()

setFireMissionIndex

public void setFireMissionIndex(int pFireMissionIndex)

getFireMissionIndex

public int getFireMissionIndex()

setLocationInWorldCoordinates

public void setLocationInWorldCoordinates(Vector3Double pLocationInWorldCoordinates)

getLocationInWorldCoordinates

public Vector3Double getLocationInWorldCoordinates()

setBurstDescriptor

public void setBurstDescriptor(BurstDescriptor pBurstDescriptor)

getBurstDescriptor

public BurstDescriptor getBurstDescriptor()

setVelocity

public void setVelocity(Vector3Float pVelocity)

getVelocity

public Vector3Float getVelocity()

setRangeToTarget

public void setRangeToTarget(float pRangeToTarget)

getRangeToTarget

public float getRangeToTarget()

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: Pdu
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.