MAK RTIspy API Documentation for HLA 1516
forwarderPortMsg.h
Go to the documentation of this file.
1 /*********************************************************************
2 ** Copyright (c) 2009 MaK Technologies, Inc.
3 ** All rights reserved.
4 *********************************************************************/
5 /*********************************************************************
6 ** $RCSfile: forwarderPortMsg.h,v $ $Revision: 1.1.2.1 $ $State: Exp $
7 *********************************************************************/
8 
9 #ifndef DtForwarderPortMsg_H_
10 #define DtForwarderPortMsg_H_
11 
16 
17 #include <vlutil/vlString.h>
18 #include <vlutil/vlUtil.h>
19 #include <vlutil/vlInetAddr.h>
20 
21 #include "rtiMsg.h"
22 #include "netForwarderPortMsg.h"
23 #include <map>
24 
25 class DtForwarderPortMsg;
26 class DtConnectionMgr;
27 
28 typedef void (*DtForwarderPortCb)(const DtForwarderPortMsg& msg, void* usr);
29 
30 
35 {
36 public:
37 
38 
40  DtForwarderPortMsg(DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER);
41 
43  DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER);
44 
46  virtual ~DtForwarderPortMsg();
47 
49  virtual DtRtiMsg* clone(bool copy = true) const;
50 
52  virtual void printData() const;
53 
55  virtual void setListeningPort(unsigned port);
56  virtual unsigned listeningPort() const;
57 
59  virtual void setConnectedPort(unsigned port);
60  virtual unsigned connectedPort() const;
61 
64  virtual void setAddress(const MAKRti::DtInetAddr& addressValue);
65  virtual MAKRti::DtInetAddr address() const;
66 
67 public:
68 
70  static DtRtiMsg* create(const DtNetMsgHeader* initial,
71  DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER);
72 
73  static DtRtiMsg* create(DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER);
74 
77  static void addCallback(DtConnectionMgr* conn,
78  DtForwarderPortCb cb, void* usr);
79  static void removeCallback(DtConnectionMgr* conn,
80  DtForwarderPortCb cb, void* usr);
81 
82 
83 protected:
84 
86  virtual DtNetForwarderPortMsg* netForwarderPortMsg();
87  virtual const DtNetForwarderPortMsg* netForwarderPortMsg() const;
88 
91 
93  virtual int minSize() const;
94 
95 
96 };
97 
98 #endif

Document ID: Generated on Fri Mar 14 19:08:55 EDT 2014 from SVN revision 137085
Copyright © 2005-2014 VT MÄK Inc. All Rights Reserved (www.mak.com)