VR-Exchange 2.5 API Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
ddsBroker/vlOpenSplice/reflectedEntity.h
Go to the documentation of this file.
1 /****************************************************************************
2  * Copyright (c) 2015 VT MAK
3  * All rights reserved.
4  ****************************************************************************/
5 
9 
10 #pragma once
11 
14 #include <vlutil/vlString.h>
15 #include <vector>
16 
17 // ************************************************************************ //
18 // Use the DIS implementation from VR-Link by temporarily defining DtDIS.
19 // ************************************************************************ //
20 #ifndef DtDIS
21 # define MUST_UNDEF_DTDIS
22 # define DtDIS 1
23 #endif
24 
25 #include <vl/entityStateRepository.h>
26 
27 #ifdef MUST_UNDEF_DTDIS
28 # undef DtDIS
29 #endif
30 
31 namespace MAKVrExchange
32 {
33 
34  namespace DtDdsBroker
35  {
36 
38  {
39  public:
40 
41  DtReflectedEntity( const char* ident );
42  DtReflectedEntity( const DtString& ident );
43 
44  virtual ~DtReflectedEntity();
45 
48 
49  virtual const DtEntityStateRepository* entityStateRep() const;
50  virtual DtEntityStateRepository* entityStateRep();
51 
52  virtual const DtEntityStateRepository* stateRep() const;
53  virtual DtEntityStateRepository* stateRep();
54 
55  virtual const DtEntityStateRepository* esr() const;
56  virtual DtEntityStateRepository* esr();
57 
58  virtual const DtEntityStateRepository* sr() const;
59  virtual DtEntityStateRepository* sr();
60 
62 
63  virtual const DtEntityIdentifier& entityId() const;
64  virtual const DtEntityIdentifier& globalId() const;
65 
66  virtual void addPostUpdateCallback( DtDdsCallbackFunction cb, void* userData );
67  virtual void removePostUpdateCallback( DtDdsCallbackFunction cb, void* userData );
68 
69  virtual void processPostUpdateCallbacks();
70 
71  private:
72 
74  DtReflectedEntity( const DtReflectedEntity& other );
75 
77  DtReflectedEntity& operator = ( const DtReflectedEntity& other );
78 
79  protected:
80 
81  typedef std::vector<DtDdsCbInfo*> DdsCallbackList;
83 
84  DtEntityIdentifier myEntityId;
85  DtEntityStateRepository* myEsr;
86 
87  };
88 
89 
90  inline const DtEntityStateRepository* DtReflectedEntity::entityStateRep() const
91  {
92  return myEsr;
93  }
94 
95  inline DtEntityStateRepository* DtReflectedEntity::entityStateRep()
96  {
97  return myEsr;
98  }
99 
100  inline const DtEntityStateRepository* DtReflectedEntity::stateRep() const
101  {
102  return myEsr;
103  }
104 
105  inline DtEntityStateRepository* DtReflectedEntity::stateRep()
106  {
107  return myEsr;
108  }
109 
110  inline const DtEntityStateRepository* DtReflectedEntity::esr() const
111  {
112  return myEsr;
113  }
114 
115  inline DtEntityStateRepository* DtReflectedEntity::esr()
116  {
117  return myEsr;
118  }
119 
120  inline const DtEntityStateRepository* DtReflectedEntity::sr() const
121  {
122  return myEsr;
123  }
124 
125  inline DtEntityStateRepository* DtReflectedEntity::sr()
126  {
127  return myEsr;
128  }
129 
130  }
131 }

Document ID: Generated on Wed Dec 21 15:05:11 EST 2016 from SVN revision 171891
Copyright © 2005-2016 VT MÄK. All Rights Reserved (www.mak.com)