Contents | Package | Class | Tree | Deprecated | Index | Help
PREV | NEXT SHOW LISTS | HIDE LISTS

Class mil.navy.nps.dis.DataQueryPdu

java.lang.Object
    |
    +----mil.navy.nps.dis.PduElement
            |
            +----mil.navy.nps.dis.ProtocolDataUnit
                    |
                    +----mil.navy.nps.dis.SimulationManagementPdu
                            |
                            +----mil.navy.nps.dis.DataQueryPdu

public class DataQueryPdu
extends SimulationManagementPdu
Version:
1.0
Author:
Antonio Alexandre Rua (http://www.garfield.fe.up.pt/~alexrua)
Location:
http://www.stl.nps.navy.mil/dis-java-vrml/mil/navy/nps/dis/DataQueryPdu.java
Hierarchy Diagram:
Summary:
A request for data from an entity shall be communicated by issuing a Data Query PDU.
Note:
We have flatenned the Data Query Datum Specification Record for the moment. This might be changed in the future if we implement some other classes that need the same record. Also note that we have implemented the fixedDatumIDlist and the variableDatumIDlist as a vector.
History:
16Sep97 /Antonio Alexandre Rua /New
8Dec97 /Ronan Fauglas /changes for documentation templates + complements in documentation
11Dec97 /Ronan Fauglas /changed access methods: thisVariable() --> getThisVariable()
References:
DIS Data Dictionary : Data Query PDU
DIS-Java-VRML Working Group: http://www.stl.nps.navy.mil/dis-java-vrml/
DIS specification : IEEE 1278.1, Section 5.4.6.8, 4.4.5.4.8
See Also:
ProtocolDataUnit, PduElement, mil.navy.nps.util.SerializationInterface

Field Summary
static DataQueryPdu  exemplar
An "exemplar" object, which is filled out to the state that is needed most of the time.
java.util.Vector  fixedDatumIDList
List of fixed datums IDs.
mil.navy.nps.util.UnsignedInt  requestID
Request ID - This field shall identify the data query request being made by the Simulation Manager.
static int  sizeOf
Constant value--size of a PDU without header(fixed, counters + requestID + timeInterval).
mil.navy.nps.util.UnsignedInt  timeInterval
Time Interval - This field shall specify the time interval between issues of Data PDUs.
java.util.Vector  variableDatumIDList
List of variable datums IDs.
 
Fields inherited from class mil.navy.nps.dis.SimulationManagementPdu
 originatingEntityID, receivingEntityID, sizeOf
 
Fields inherited from class mil.navy.nps.dis.ProtocolDataUnit
 DEBUG, exerciseID, pduType, protocolFamily, protocolVersion, sizeOf, timestamp
 

Constructor Summary
 DataQueryPdu()
Default constructor--fills with zeros for all values.
 

Method Summary
void  addFixedDatumID(long pFixedDatumID)
Adds a Fixed Datum ID at the end of the list.
void  addVariableDatumID(long pVariableDatumID)
Inserts a Variable Datum ID at the end of the list.
java.lang.Object  clone()
 
void  deSerialize(java.io.DataInputStream inputStream)
 
void  dropFixedDatumID()
Suppress the current Fixed Datum ID list
void  dropVariableDatumID()
Suppress the current Fixed Datum ID list
long  fixedDatumIDAt(int pIdx)
Returns the Fixed Datum ID at the index given in parameter.
int  fixedDatumIDCount()
Returns the size of the List of fixed datums IDs.
DataQueryPdu  getExemplar()
 
mil.navy.nps.util.UnsignedInt  getRequestID()
 
mil.navy.nps.util.UnsignedInt  getTimeInterval()
 
int  length()
 
java.lang.String  PDUName()
 
void  printValues(int indentLevel, java.io.PrintStream printStream)
 
void  serialize(java.io.DataOutputStream outputStream)
 
void  setActionID(long pActionID)
 
void  setExemplar(DataQueryPdu newExemplar)
 
void  setRequestID(long pRequestID)
 
long  variableDatumIDAt(int pIdx)
Returns the Variable Datum ID at the index given in parameter.
int  variableDatumIDCount()
Returns the size of the List of Variable datums IDs.
 
Methods inherited from class mil.navy.nps.dis.SimulationManagementPdu
 clone, deSerialize, getOriginatingEntityID, getReceivingEntityID, length, PDUName, printValues, serialize, setOriginatingEntityID, setReceivingEntityID
 
Methods inherited from class mil.navy.nps.dis.ProtocolDataUnit
 , clone, datagramToPdu, deSerialize, getExerciseID, getPduType, getProtocolFamily, getProtocolVersion, getTimestamp, getVRMLTimestamp, length, makeTimestampCurrent, PDUName, printValues, serialize, setExerciseID, setExerciseID, setPduType, setPduType, setProtocolFamily, setProtocolFamily, setProtocolVersion, setProtocolVersion, setSimulationStartTime, setTimestamp, setTimestamp
 
Methods inherited from class mil.navy.nps.dis.PduElement
 clone, deSerialize, length, printValues, serialize
 
Methods inherited from class java.lang.Object
 clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

requestID

protected mil.navy.nps.util.UnsignedInt requestID
Request ID - This field shall identify the data query request being made by the Simulation Manager.
Value:
A 32-bit monotonically increasing integer identifier inserted by the Simulation Manager into all Simulation Manager PDUs.
References:
DIS Data Dictionary: Request ID Field

timeInterval

protected mil.navy.nps.util.UnsignedInt timeInterval
Time Interval - This field shall specify the time interval between issues of Data PDUs.
Value:
A value of zero in this field shall mean that the requested data should be sent once and not at any previously specified time interval.
References:
DIS Data Dictionary: Time Stamp Field
DIS specification : IEEE 1278.1, 5.3.31

fixedDatumIDList

protected java.util.Vector fixedDatumIDList
List of fixed datums IDs.
References:
See section 7 in the EBV-DOC
DIS Data Dictionary: Datum ID Field

variableDatumIDList

protected java.util.Vector variableDatumIDList
List of variable datums IDs.
References:
See section 7 in the EBV-DOC
DIS Data Dictionary: Datum ID Field

sizeOf

public static final int sizeOf
Constant value--size of a PDU without header(fixed, counters + requestID + timeInterval). sizeOf = 16 bytes

exemplar

protected static DataQueryPdu exemplar
An "exemplar" object, which is filled out to the state that is needed most of the time.
Explanation
A brand new object has to have most of its values set, such as the forceID, protocol version, and so on. This lets the user fill out most of the values, save it in the class, then retrieve a copy of it as needed.
Constructor Detail

DataQueryPdu

public DataQueryPdu()
Default constructor--fills with zeros for all values.
Method Detail

PDUName

public java.lang.String PDUName()
Overrides:
PDUName in class SimulationManagementPdu

serialize

public void serialize(java.io.DataOutputStream outputStream)
Overrides:
serialize in class SimulationManagementPdu

deSerialize

public void deSerialize(java.io.DataInputStream inputStream)
Overrides:
deSerialize in class SimulationManagementPdu

clone

public java.lang.Object clone()
Overrides:
clone in class SimulationManagementPdu

length

public int length()
Overrides:
length in class SimulationManagementPdu

printValues

public void printValues(int indentLevel,
                        java.io.PrintStream printStream)
Overrides:
printValues in class SimulationManagementPdu

getExemplar

public DataQueryPdu getExemplar()

setExemplar

public void setExemplar(DataQueryPdu newExemplar)

getRequestID

public mil.navy.nps.util.UnsignedInt getRequestID()

setRequestID

public void setRequestID(long pRequestID)

getTimeInterval

public mil.navy.nps.util.UnsignedInt getTimeInterval()

setActionID

public void setActionID(long pActionID)

fixedDatumIDCount

public int fixedDatumIDCount()
Returns the size of the List of fixed datums IDs.
Returns:
the size of the List of fixed datums IDs

variableDatumIDCount

public int variableDatumIDCount()
Returns the size of the List of Variable datums IDs.
Returns:
the size of the List of Variable datums IDs

addFixedDatumID

public void addFixedDatumID(long pFixedDatumID)
Adds a Fixed Datum ID at the end of the list.
Parameters:
pFixedDatumID - the Fixed Datum ID to be inserted in the list

fixedDatumIDAt

public long fixedDatumIDAt(int pIdx)
Returns the Fixed Datum ID at the index given in parameter.
Parameters:
pIdx - the index of the Fixed Datum ID we want to obtain
Returns:
the the Fixed Datum ID pointed by the index in parameter

dropFixedDatumID

public void dropFixedDatumID()
Suppress the current Fixed Datum ID list

addVariableDatumID

public void addVariableDatumID(long pVariableDatumID)
Inserts a Variable Datum ID at the end of the list.
Parameters:
pVariableDatumID - the Variable Datum ID to be inserted in the list

variableDatumIDAt

public long variableDatumIDAt(int pIdx)
Returns the Variable Datum ID at the index given in parameter.
Parameters:
pIdx - the index of the Variable Datum ID we want to obtain
Returns:
the Variable Datum ID pointed by the index in parameter

dropVariableDatumID

public void dropVariableDatumID()
Suppress the current Fixed Datum ID list

Contents | Package | Class | Tree | Deprecated | Index | Help
PREV | NEXT SHOW LISTS | HIDE LISTS