50 typedef DtPdu* (*DtPduInterceptFcn)(
DtPdu* pdu,
int *retCode);
65 typedef int (*DtPredicate)(
DtPdu *pdu,
void *arg);
69 DtNET_READ_SUCCESS =0,
70 DtNET_READ_NO_PACKETS =1,
71 DtNET_READ_BAD_PACKET =2,
72 DtNET_READ_SERVER_MSG =3,
73 DtNET_READ_SIZE_MISMATCH =4
77 DtPROCESS_PDU_SUCCESS =0,
78 DtPROCESS_PDU_WRONG_EXID =5,
79 DtPROCESS_PDU_NO_PDU =6,
80 DtNET_READ_FILTERED_PACKET =7
93 DtCOULD_NOT_CREATE_SOCKET =1
109 int site_id,
int application_num,
110 InitializationStatus* status = 0,
bool use_async_io =
false,
111 bool useIpv6 =
false,
bool suppressSelfReflect =
false);
116 int site_id,
int application_num, InitializationStatus* status = 0,
117 bool use_async_io =
false,
bool suppressSelfReflect =
false);
122 int site_id,
int application_num, InitializationStatus* status = 0);
153 virtual int drainInput(
DtTime timeout=-1,
int nReadPerTimeCheck=100);
157 virtual int readAndProcess(
void);
162 virtual int processPdu(
DtPdu *pdu);
168 virtual DtPdu *netRead(
int *retCode = 0);
175 virtual void addInterestInPduKind(
DtPduKind kind);
182 virtual void subtractInterestInPduKind(
DtPduKind kind);
188 virtual DtPduKind readUntil(DtPredicate predicate,
void *arg,
193 virtual void addInterestInMcastAddr(
const DtInetAddr& addr);
197 virtual void subtractInterestInMcastAddr(
const DtInetAddr& addr);
236 virtual bool addDestination(
const DtInetAddr& destination,
DtU16 port=0);
244 virtual bool removeDestination(
const DtInetAddr& destination,
DtU16 port=0);
247 virtual void setExerciseId(
int exercise_id);
295 virtual void enableFiltering();
298 virtual void disableFiltering();
309 virtual void setTimeStampType(
int relOrAbs);
322 void setRelativeTimeRatio(
float ratio);
323 float relativeTimeRatio();
347 virtual DtTime currentTimeForStamping();
350 void init0(
int port,
int exerId,
int siteId,
int applNum,
352 bool suppressSelfReflect);
355 void init0(
DtInetSocket* s,
int exerId,
int siteId,
int applNum,
358 virtual void setRemoteEndpoint(
const DtInetAddr& addr,
int port );
365 bool useAsyncIo,
DtInetDevice* device,
bool suppressSelfReflect);
373 void zeroPduInterestList();
406 bool suppressSelfReflect)
412 , myEndpointReceivedFrom()
413 , myOwnershipHandler(0)
414 , myPduInterceptor(0)
417 init0(po, ex, si, ap, status, use_async_io, useIpv6, suppressSelfReflect);
428 , myEndpointReceivedFrom()
429 , myOwnershipHandler(0)
430 , myPduInterceptor(0)
433 init0(so, ex, si, ap, status);
DtInteraction is an base class for representing DIS PDUs which don't have state.
Definition: interactionDIS.h:24
This file contains the declaration of the DtInetSocket base class.
Instances of DtExerciseConn are used to provide an application's interface or connection to the netwo...
Definition: exerciseConnDIS.h:61
DtInetEndpoint myRemoteEndpoint
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:390
DtDisObjectManager * myDisObjectManager
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:385
#define DT_DLL_VL
Definition: vlMachineTypes.h:108
Instances of DtExerciseConnInitializer are used to provide the DtExerciseConn with initialization dat...
Definition: exerciseConnInitializerDIS.h:36
bool filtering
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:375
A DIS Exercise connection will create an instance of this class which allows state repository extensi...
Definition: stateRepositoryExtensionDecoderFactory.h:23
DtBaseExerciseConn & operator=(const DtBaseExerciseConn &)
Assignment Operator – Not Implemented.
std::vector< DtInetBuffer * > DtInetBufferChain
Socket state enumeration.
Definition: vlInetSocket.h:105
DtPduFactory * myPduFact
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:377
virtual DtInetSocket * socket()
Returns the current DtDisSocket that we are using for communication.
Definition: exerciseConnDIS.h:484
Definition: vlTimeStampType.h:18
No error, call was sucessful.
Definition: exerciseConnDIS.h:69
The DtInetSocket class provides a protocol independant, address family independant base class for TCP...
Definition: vlInetSocket.h:201
DtBaseExerciseConn is an abstract base class.
Definition: baseExerciseConn.h:31
DtPduInterceptFcn myPduInterceptor
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:387
This file declares macros which specify the VR-Link version.
DtPduEncoderFactory * myPduEncFact
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:379
DtTimeStampType myRelOrAbs
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:384
class DtPduFactory:
Definition: pduFactory.h:38
DtHashlist mcastAddrs
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:376
DtPdu *(* DtPduInterceptFcn)(DtPdu *pdu, int *retCode)
PDU intercept function signature.
Definition: exerciseConnDIS.h:50
virtual DtDisObjectManager * disObjectManager()
Get the disObjectManager.
Definition: exerciseConnDIS.h:489
void init0(int port, int exerId, int siteId, int applNum, InitializationStatus *status, bool async_io, bool useIpv6, bool suppressSelfReflect)
Called by constructor.
virtual int processPdu(DtPdu *pdu)
Called by readAndProcess (which is called by drainInput).
This file contains the declaration of the DtInetEndpoint class.
float myRelativeTimeRatio
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:397
The DtInetEndpoint class provides a protocol independant, address family independent mechanism to rep...
Definition: vlInetEndpoint.h:33
Instances of DtPduEncoderFactory are used to create encoders which know how to encode a state reposit...
Definition: pduEncoderFactory.h:19
The DtDisSocket class provides an address family independent datagram socket.
Definition: vlDisSocket.h:75
static const int nSizeMismatchComplain
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:339
This file defines math constants and methods which may be useful in simulations.
DtInetEndpoint myEndpointReceivedFrom
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:394
virtual void sendStamped(const DtStateMsg &msg)=0
Send a state message to the network which has been time stamped with the current time.
virtual DtPduDecoderFactory * pduDecoderFactory()
Get the factory used to convert pdu information to the VR-Link State Repositories.
Definition: exerciseConnDIS.h:468
Defines DtHashlist and several helper functions.
Represents a IPv4 or IPv6 address.
Definition: vlInetAddr.h:36
Definition: vlAttributePduStrategy.h:19
DtAttributePduStrategy myAttributePduStrategy
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:400
DtInetBuffer myBuffer
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:392
DtEventID myCurrentEventId
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:383
virtual void send(const DtStateMsg &msg)=0
Send a state message to the network.
DtPdu is the base class for all PDU's in VR-Link.
Definition: pdu.h:69
const DtExerciseId DtAnyExercise
Used to indicate we are interested in all exercises.
Definition: exerciseConnDIS.h:47
InitializationStatus
InitializationStatus enumerates possible values to be returned by the ExerciseConns's optional 'statu...
Definition: exerciseConnDIS.h:91
DtStateRepositoryExtensionEncoderFactory * myStateRepoExtensionEncFac
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:381
std::vector< char > DtInetBuffer
Socket state enumeration.
Definition: vlInetSocket.h:104
DtAttributePduStrategy
Definition: vlAttributePduStrategy.h:16
const DtExerciseId DtMaxExerciseId
A total of 255 exercises can be supported.
Definition: exerciseConnDIS.h:45
DtInetBufferChain myBufferChain
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:391
Represents Events in DIS.
Definition: eventId.h:154
This file contains the declaration of the DtInetAddr class.
DtPduDecoderFactory * myPduDecFact
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:380
Definition: vlInetDevice.h:101
int availEventNum
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:369
DtInetSocket * mySocket
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:389
virtual DtExerciseId exerciseId() const
Get the current exercise ID.
Definition: exerciseConnDIS.h:451
virtual DtPdu * netRead(int *retCode=0)
Reads the network, users should seldom need to call this function.
DtPduCallbackManager myPduCbMgr
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:371
char * myPacketBuffer
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:393
int socket(int, int, int)
#define DtDEFAULT_SOCK_BUFF_SIZE
Definition: vlInet.h:69
DtExerciseConn(const DtExerciseConnInitializer &initial, InitializationStatus *status=0)
The preferred constructor.
virtual DtPduEncoderFactory * pduEncoderFactory()
Get the factory used to convert pdu information from the VR-Link State Repositories.
Definition: exerciseConnDIS.h:462
class DtPduCallbackManager:
Definition: pduCallbackManager.h:27
This file contains the declaration of the DtInetDevice class.
virtual DtStateRepositoryExtensionEncoderFactory * stateRepoExtensionEncoderFactory()
Get the factory used to convert information from the VR-Link State Repositories Extensions to attribu...
Definition: exerciseConnDIS.h:473
DtHashlist is deprecated and provided for backwards compatibility only.
Definition: vlHashlist.h:69
This is a base class meant to encapsulate user callbacks on ownership management services.
Definition: ownershipHandlerDIS.h:39
DtOwnershipHandler * myOwnershipHandler
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:386
unsigned short DtU16
A 16 bit unsigned integer value.
Definition: vlMachineTypes.h:140
Contains the standard DIS enumerations.
void(* DtPduCallbackFcn)(DtPdu *pdu, void *usr)
PDU callback function signature.
Definition: pduCallbackManager.h:19
Definition: vlAttributePduStrategy.h:20
DtStateRepositoryExtensionDecoderFactory * myStateRepoExtensionDecFac
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:382
virtual DtStateRepositoryExtensionDecoderFactory * stateRepoExtensionDecoderFactory()
Get the factory used to convert PDU attribute records to the VR-Link State Repositories Extensions...
Definition: exerciseConnDIS.h:478
DtTimeStampType
Definition: vlTimeStampType.h:16
int DtProtocolVersionToSend
Contains the DtEventId class declaration.
DtPduKind
([UID 4]) - PDU Type
Definition: disEnums.h:238
#define DtMAX_PDU_KINDS
Definition: pduCallbackManager.h:73
int nSizeMismatch
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:374
Instances of DtString are used to represent strings.
Definition: vlString.h:29
DtPduFactory * myDfltPduFact
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:378
DtExerciseId myExerciseId
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:368
This file provides a declaration of the class DtBaseExerciseConn.
virtual int readAndProcess(void)
Called by drainInput, so application code rarely needs to use this.
Definition: exerciseConnDIS.h:436
Instances of DtStateMsg are used to represent state data communicated via the network in a DIS (as op...
Definition: stateMsgDIS.h:21
Instances of DtPduDecoderFactory are used to create Decoders which know how to encode a state reposit...
Definition: pduDecoderFactory.h:18
int deleteSocket
For VR-Link use only, should not be considered part of the public interface.
Definition: exerciseConnDIS.h:370
DtU16 DtExerciseId
Definition: baseExerciseConn.h:16
This file contains typedefs for machine dependant types.
virtual DtPduFactory * pduFactory()
Get the PDU factory used by netRead to create the right kind of derived DtPDU.
Definition: exerciseConnDIS.h:456
A DIS Exercise connection will create an instance of this class which allows state repository extensi...
Definition: stateRepositoryExtensionEncoderFactory.h:23
Instances of DtDisObjectManager are used to manage the set of DIS objects known to the federate...
Definition: disObjectManager.h:21