VR-Link API Documentation for HLA 1516
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
envObjectSync.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 1992-2010 VT MAK
3 ** All rights reserved.
4 ******************************************************************************/
5 
6 
10 
11 #ifndef envObjectSync_H__
12 #define envObjectSync_H__
13 
14 #include "appEnv.h"
15 #include <vlutil/vlString.h>
16 #include <vlutil/vlSmartPointers.h>
17 #include <utility>
18 #include <map>
19 
20 #include "envValue.h"
21 
22 #ifdef DtUSE_UTILITIES_NAMESPACE
23 namespace DtUSE_UTILITIES_NAMESPACE
24 {
25 #endif
26 
30 
31 typedef DtBoost::weak_ptr<DtEnvObjectSync> DtEnvObjectSyncWP;
32 
36 {
37 public:
38 
40 
41  virtual ~DtEnvObjectSync();
42 
45  virtual void generateObject(DtEnvironment&, const DtString& name);
46 
51  virtual void bind(DtEnvValueSP value,bool createMissingAttributes);
52 
56  virtual void unbind();
57 
60  virtual DtEnvValueSP binding() const;
61 
64  virtual void addAttributeSync(const DtString&,DtEnvObjectSync*);
65 
68  virtual void removeAttributeSync(const DtString&);
69 
71  virtual void removeAllAttributeSyncs();
72 
74  virtual DtEnvObjectSync* attributeSync(const DtString&);
75 
76 
77  /* CALLBACKS */
78 
79  /* Mandatory callbacks */
80 
84  virtual void syncInCB(const DtEnvObject&) = 0;
85 
88  virtual void syncOutCB(DtEnvObject&) const = 0;
89 
91  virtual DtString syncType() const = 0;
92 
93  /* Optional callbacks */
94 
96  virtual void unboundAttributeSyncInCB(DtEnvValue*);
97 
99  virtual void attributeAddedCB(DtEnvValueSP);
100 
102  virtual void attributeRemovedCB(DtEnvValueSP);
103 
104 protected:
105 
106 
107  //typedef std::pair<DtEnvObjectSync*,DtEnvValueSP> DtAttributeBinding;
108  typedef std::map<DtString,DtEnvObjectSync*> DtAttributeSyncMap;
111 };
112 
113 #ifdef DtUSE_UTILITIES_NAMESPACE
114 }
115 #endif
116 
117 #endif

Document ID: Generated on Wed Jan 7 13:31:29 EST 2015 from SVN revision 149162
Copyright © 2005-2014 VT MÄK. All Rights Reserved (www.mak.com)