Package edu.nps.moves.dis7.pdus
Class AttributePdu
java.lang.Object
edu.nps.moves.dis7.pdus.Pdu
edu.nps.moves.dis7.pdus.PduBase
edu.nps.moves.dis7.pdus.EntityInformationInteractionFamilyPdu
edu.nps.moves.dis7.pdus.AttributePdu
- All Implemented Interfaces:
Marshaller,Serializable
7.2.6. Information about individual attributes for a particular entity, other object, or event may be communicated using an Attribute PDU. The Attribute PDU shall not be used to exchange data available in any other PDU except where explicitly mentioned in the PDU issuance instructions within this standard. See 5.3.6.
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected DISAttributeActionCodeThis field shall identify the action code applicable to this Attribute PDU.protected DisPduTypeThis field shall represent the type of the PDU that is being extended or updated, if applicable.protected DISProtocolFamilyThis field shall indicate the Protocol Version associated with the Attribute Record PDU Type.protected List<AttributeRecordSet> attributeRecordSets is an undescribed parameter...protected ByteArrayOutputStreambyteArrayOutputStream (baos) is used for marshal/unmarshal serializationprotected DataOutputStreamdataOutputStream (dos) is used for marshal/unmarshal serializationprotected VariableRecordTypeThis field shall contain the Attribute record type of the Attribute records in the PDU if they all have the same Attribute record type.static final StringThe name of this PDU typeprotected shortThis field shall specify the number of Attribute Record Sets that make up the remainder of the PDU.protected SimulationAddressThis field shall identify the simulation issuing the Attribute PDU.protected intPaddingprotected shortPaddingprotected bytePaddingFields inherited from class edu.nps.moves.dis7.pdus.EntityInformationInteractionFamilyPdu
FAMILY_NAMEFields inherited from class edu.nps.moves.dis7.pdus.Pdu
exerciseID, length, pduType, protocolFamily, protocolVersion, timestamp -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncopy()copy method creates a deep copy of current object using preferred marshalling methodCreates a "deep copy" of current object using ByteBuffer methods.copy method creates a deep copy of current object using DataOutputStream methods.booleanbooleanequalsImpl(Object obj) Compare all fields that contribute to the state, ignoring transient and static fields, forthisand the supplied objectGetter foractionCodeGetter forattributeRecordPduTypeGetter forattributeRecordProtocolVersionGetter forattributeRecordSetsintReturns size of this serialized (marshalled) object in bytesGetter formasterAttributeRecordTypeGetter fororiginatingSimulationAddressintGetter forpadding1shortGetter forpadding2byteGetter forpadding3inthashCode()voidmarshal(DataOutputStream dos) Serializes an object to a DataOutputStream.voidmarshal(ByteBuffer byteBuffer) Packs an object into the ByteBuffer.setActionCode(DISAttributeActionCode pActionCode) Setter foractionCodesetAttributeRecordPduType(DisPduType pAttributeRecordPduType) Setter forattributeRecordPduTypesetAttributeRecordProtocolVersion(DISProtocolFamily pAttributeRecordProtocolVersion) Setter forattributeRecordProtocolVersionsetAttributeRecordSets(List<AttributeRecordSet> pAttributeRecordSets) Setter forattributeRecordSetssetMasterAttributeRecordType(VariableRecordType pMasterAttributeRecordType) Setter formasterAttributeRecordTypesetOriginatingSimulationAddress(SimulationAddress pOriginatingSimulationAddress) Setter fororiginatingSimulationAddresssetPadding1(int pPadding1) Setter forpadding1setPadding2(int pPadding2) Utility setter forpadding2setPadding2(short pPadding2) Setter forpadding2setPadding3(byte pPadding3) Setter forpadding3setPadding3(int pPadding3) Utility setter forpadding3toString()intunmarshal(DataInputStream dis) Deserializes an object from a DataInputStream.intunmarshal(ByteBuffer byteBuffer) Unpacks a Pdu from the underlying data.Methods inherited from class edu.nps.moves.dis7.pdus.PduBase
getPadding, getPduStatus, setPadding, setPadding, setPduStatusMethods inherited from class edu.nps.moves.dis7.pdus.Pdu
copyByPduFactory, getExerciseID, getLength, getPduType, getProtocolFamily, getProtocolVersion, getTimestamp, getTimestampSeconds, isAcknowledgeRPdu, isActionRequestPdu, isActionRequestRPdu, isActionResponsePdu, isActionResponseRPdu, isAggregateStatePdu, isAppearancePdu, isArealObjectStatePdu, isArticulatedPartsPdu, isAttributePdu, isCollisionElasticPdu, isCollisionPdu, isCommentPdu, isCommentRPdu, isCreateEntityPdu, isCreateEntityRPdu, isDataPdu, isDataQueryPdu, isDataQueryRPdu, isDataRPdu, isDesignatorPdu, isDetonationPdu, isDirectedEnergyFirePdu, isDistributedEmissionsRegenerationFamilyPdu, isElectromagneticEmissionPdu, isEntityDamageStatusPdu, isEntityInformationInteractionFamilyPdu, isEntityManagementFamilyPdu, isEntityStatePdu, isEntityStateUpdatePdu, isEnvironmentalProcessPdu, isEventReportPdu, isEventReportRPdu, isFirePdu, isGriddedDataPdu, isIFFPdu, isInformationOperationsActionPdu, isInformationOperationsFamilyPdu, isInformationOperationsReportPdu, isIntercomControlPdu, isIntercomSignalPdu, isIsGroupOfPdu, isIsPartOfPdu, isLEDetonationPdu, isLEFirePdu, isLinearObjectStatePdu, isLiveEntityDetonationPdu, isLiveEntityFirePdu, isLogisticsFamilyPdu, isMinefieldDataPdu, isMinefieldFamilyPdu, isMinefieldQueryPdu, isMinefieldResponseNACKPdu, isMinefieldStatePdu, isPointObjectStatePdu, isRadioCommunicationsFamilyPdu, isReceiverPdu, isRecordQueryRPdu, isRecordRPdu, isReliablePdu, isRemoveEntityPdu, isRemoveEntityRPdu, isRepairCompletePdu, isRepairResponsePdu, isResupplyCancelPdu, isResupplyOfferPdu, isResupplyReceivedPdu, isSEESPdu, isSetDataPdu, isSetDataRPdu, isSetRecordRPdu, isSignalPdu, isSimulationManagementFamilyPdu, isSimulationManagementWithReliabilityFamilyPdu, isStartResumePdu, isStartResumeRPdu, isStopFreezePdu, isStopFreezeRPdu, isSupplementalEmissionEntityStatePdu, isSyntheticEnvironmentFamilyPdu, isTransferOwnershipPdu, isTransmitterPdu, isTSPIPdu, isUnderwaterAcousticPdu, isWarfareFamilyPdu, marshal, occursAfter, occursBefore, occursSameTime, setExerciseID, setExerciseID, setLength, setLength, setPduType, setProtocolFamily, setProtocolVersion, setTimestamp, setTimestampSeconds
-
Field Details
-
NAME
-
originatingSimulationAddress
This field shall identify the simulation issuing the Attribute PDU. It shall be represented by a Simulation Address record (see 6.2.79). -
padding1
protected int padding1Padding -
padding2
protected short padding2Padding -
attributeRecordPduType
This field shall represent the type of the PDU that is being extended or updated, if applicable. It shall be represented by an 8-bit enumeration. uid 4 -
attributeRecordProtocolVersion
This field shall indicate the Protocol Version associated with the Attribute Record PDU Type. It shall be represented by an 8-bit enumeration. uid 5 -
masterAttributeRecordType
This field shall contain the Attribute record type of the Attribute records in the PDU if they all have the same Attribute record type. It shall be represented by a 32-bit enumeration. uid 66 Variable Record Type values are defined by VariableRecordType enumerations -
actionCode
This field shall identify the action code applicable to this Attribute PDU. The Action Code shall apply to all Attribute records contained in the PDU. It shall be represented by an 8-bit enumeration. uid 295 -
padding3
protected byte padding3Padding -
numberAttributeRecordSet
protected short numberAttributeRecordSetThis field shall specify the number of Attribute Record Sets that make up the remainder of the PDU. It shall be represented by a 16-bit unsigned integer. -
attributeRecordSets
attributeRecordSets is an undescribed parameter... -
byteArrayOutputStream
byteArrayOutputStream (baos) is used for marshal/unmarshal serialization- See Also:
-
dataOutputStream
dataOutputStream (dos) is used for marshal/unmarshal serialization- See Also:
-
-
Constructor Details
-
AttributePdu
public AttributePdu()Constructor creates and configures a new instance object
-
-
Method Details
-
copy
copy method creates a deep copy of current object using preferred marshalling method- Returns:
- deep copy of PDU
-
copyByteBuffer
Creates a "deep copy" of current object using ByteBuffer methods.- Returns:
- deep copy of PDU
-
copyDataOutputStream
copy method creates a deep copy of current object using DataOutputStream methods.- Returns:
- deep copy of PDU
-
getMarshalledSize
public int getMarshalledSize()Returns size of this serialized (marshalled) object in bytes- Specified by:
getMarshalledSizein interfaceMarshaller- Overrides:
getMarshalledSizein classEntityInformationInteractionFamilyPdu- Returns:
- serialized size in bytes
- See Also:
-
setOriginatingSimulationAddress
public AttributePdu setOriginatingSimulationAddress(SimulationAddress pOriginatingSimulationAddress) Setter fororiginatingSimulationAddress- Parameters:
pOriginatingSimulationAddress- new value of interest- Returns:
- same object to permit progressive setters
-
getOriginatingSimulationAddress
Getter fororiginatingSimulationAddress- Returns:
- value of interest
-
setPadding1
Setter forpadding1- Parameters:
pPadding1- new value of interest- Returns:
- same object to permit progressive setters
-
getPadding1
-
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
-
setAttributeRecordPduType
Setter forattributeRecordPduType- Parameters:
pAttributeRecordPduType- new value of interest- Returns:
- same object to permit progressive setters
-
getAttributeRecordPduType
Getter forattributeRecordPduType- Returns:
- value of interest
-
setAttributeRecordProtocolVersion
public AttributePdu setAttributeRecordProtocolVersion(DISProtocolFamily pAttributeRecordProtocolVersion) Setter forattributeRecordProtocolVersion- Parameters:
pAttributeRecordProtocolVersion- new value of interest- Returns:
- same object to permit progressive setters
-
getAttributeRecordProtocolVersion
Getter forattributeRecordProtocolVersion- Returns:
- value of interest
-
setMasterAttributeRecordType
Setter formasterAttributeRecordType- Parameters:
pMasterAttributeRecordType- new value of interest- Returns:
- same object to permit progressive setters
-
getMasterAttributeRecordType
Getter formasterAttributeRecordType- Returns:
- value of interest
-
setActionCode
Setter foractionCode- Parameters:
pActionCode- new value of interest- Returns:
- same object to permit progressive setters
-
getActionCode
-
setPadding3
Setter forpadding3- Parameters:
pPadding3- new value of interest- Returns:
- same object to permit progressive setters
-
setPadding3
Utility setter forpadding3- Parameters:
pPadding3- new value of interest- Returns:
- same object to permit progressive setters
-
getPadding3
-
setAttributeRecordSets
Setter forattributeRecordSets- Parameters:
pAttributeRecordSets- new value of interest- Returns:
- same object to permit progressive setters
-
getAttributeRecordSets
Getter forattributeRecordSets- Returns:
- value of interest
-
marshal
Serializes an object to a DataOutputStream.- Specified by:
marshalin interfaceMarshaller- Overrides:
marshalin classEntityInformationInteractionFamilyPdu- Parameters:
dos- the OutputStream- Throws:
Exception- if something goes wrong- See Also:
-
unmarshal
Deserializes an object from a DataInputStream.- Specified by:
unmarshalin interfaceMarshaller- Overrides:
unmarshalin classEntityInformationInteractionFamilyPdu- 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.- Specified by:
marshalin interfaceMarshaller- Overrides:
marshalin classEntityInformationInteractionFamilyPdu- 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.- Specified by:
unmarshalin interfaceMarshaller- Overrides:
unmarshalin classEntityInformationInteractionFamilyPdu- 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
- Overrides:
equalsin classEntityInformationInteractionFamilyPdu
-
equalsImpl
Description copied from class:PduCompare all fields that contribute to the state, ignoring transient and static fields, forthisand the supplied object- Overrides:
equalsImplin classEntityInformationInteractionFamilyPdu- Parameters:
obj- the object to compare to- Returns:
- true if the objects are equal, false otherwise.
-
toString
- Overrides:
toStringin classEntityInformationInteractionFamilyPdu
-
hashCode
-