All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
InteriorsEntitiesRepository.h
1 // Copyright eeGeo Ltd (2012-2015), All Rights Reserved
2 
3 #pragma once
4 
5 #include "Interiors.h"
6 #include "CallbackCollection.h"
7 
8 #include <vector>
9 #include <map>
10 #include <string>
11 
12 namespace Eegeo
13 {
14  namespace Resources
15  {
16  namespace Interiors
17  {
18  namespace Entities
19  {
20  typedef std::vector<InteriorsEntityModel*> TEntityModelVector;
21  typedef std::map<std::string, TEntityModelVector> TInteriorToEntitiesMap;
22 
24  {
25  public:
26  const TEntityModelVector& GetAllStreamedEntitiesForInterior(const std::string& interiorName);
27  void AddEntitiesForInterior(const std::string& interiorName, const TEntityModelVector& entities);
28  void RemoveEntitiesForInterior(const std::string& interiorName, const TEntityModelVector& entities);
29 
30  void RegisterEntitiesAddedCallback(Helpers::ICallback2<const std::string&, const TEntityModelVector&>& callback);
31  void UnregisterEntitiesAddedCallback(Helpers::ICallback2<const std::string&, const TEntityModelVector&>& callback);
32  void RegisterEntitiesRemovedCallback(Helpers::ICallback2<const std::string&, const TEntityModelVector&>& callback);
33  void UnregisterEntitiesRemovedCallback(Helpers::ICallback2<const std::string&, const TEntityModelVector&>& callback);
34 
35  private:
36 
37  TInteriorToEntitiesMap m_interiorToEntities;
38 
41  };
42  }
43  }
44  }
45 }