refactor: add TransCache

This commit is contained in:
Christopher Mosher
2013-12-15 14:00:43 -05:00
parent 90145f3d37
commit d3068e35e6
7 changed files with 77 additions and 27 deletions
+3 -2
View File
@@ -12,6 +12,7 @@
#include <set>
#include <memory>
class TransCache;
class SegmentCache;
class Common;
class Trans;
@@ -19,7 +20,7 @@ class Trans;
class TransNetwork final {
public:
TransNetwork(std::istream& readFromHere, SegmentCache& segs);
TransNetwork(std::istream& readFromHere, SegmentCache& segs, TransCache& transes);
private:
@@ -27,7 +28,7 @@ private:
TransNetwork& operator=(const TransNetwork&) = delete;
SegmentCache& segs;
std::set<std::shared_ptr<Trans>> transes;
TransCache& transes;
friend Common;
};