1
2
3
4
5
6 #ifndef CMAJOR_BINDER_CONCEPT_REPOSITORY_INCLUDED
7 #define CMAJOR_BINDER_CONCEPT_REPOSITORY_INCLUDED
8 #include <cmajor/binder/BoundConstraint.hpp>
9 #include <cmajor/symbols/ConceptSymbol.hpp>
10
11 namespace cmajor { namespace binder {
12
13 using namespace cmajor::symbols;
14
15 class ConceptRepository
16 {
17 public:
18 BoundConcept* GetBoundConcept(const BoundConceptKey& key) const;
19 void AddBoundConcept(const BoundConceptKey& key, std::std::unique_ptr<BoundConcept>&&boundConcept);
20 private:
21 std::unordered_map<BoundConceptKey, BoundConcept*, BoundConceptKeyHash> boundConceptMap;
22 std::vector<std::std::unique_ptr<BoundConcept>>boundConcepts;
23 };
24
25 } }
26
27 #endif // CMAJOR_BINDER_CONCEPT_REPOSITORY_INCLUDED