All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
IResourceObserver.h
1 // Copyright eeGeo Ltd (2012-2014), All Rights Reserved
2 
3 #pragma once
4 
5 #include "Types.h"
6 #include "Labels.h"
7 
8 #include "ICallback.h"
9 #include "CallbackCollection.h"
10 
11 namespace Eegeo
12 {
13  namespace Labels
14  {
15  // todo move to Resources namespace
16 
17  template<typename TResourceType>
19  {
20  public:
21  typedef const TResourceType CallbackParamType;
23 
24  virtual ~IResourceObserver() {;}
25 
26  virtual void RegisterAddedToSceneGraphCallback(CallbackType& callback) = 0;
27  virtual void UnregisterAddedToSceneGraphCallback(CallbackType& callback) = 0;
28 
29  virtual void RegisterRemovedFromSceneGraphCallback(CallbackType& callback) = 0;
30  virtual void UnregisterRemovedFromSceneGraphCallback(CallbackType& callback) = 0;
31 
32  virtual void RegisterResourceDeletedCallback(CallbackType& callback) = 0;
33  virtual void UnregisterResourceDeletedCallback(CallbackType& callback) = 0;
34 
35  virtual void NotifyAddedToSceneGraph(CallbackParamType& resource) = 0;
36  virtual void NotifyRemovedFromSceneGraph(CallbackParamType& resource) = 0;
37  virtual void NotifyResourceDeleted(CallbackParamType& resource) = 0;
38  };
39  }
40 }