27 #include <MemoryX/interface/components/PriorKnowledgeInterface.h>
28 #include <MemoryX/interface/components/CommonStorageInterface.h>
43 defineRequiredProperty<std::string>(
"ClassCollections",
"Comma separated list of MongoDB collection (<db>.<collection>) which store known object classes. First collection will be used for writing.");
44 defineOptionalProperty<std::string>(
"RelationCollections",
"",
"Comma separated list of MongoDB collection (<db>.<collection>) which store known object classes relations. First collection will be used for writing.");
45 defineOptionalProperty<std::string>(
"GraphCollections",
"",
"Comma separated list of MongoDB collection (<db>.<collection>) which store graphs. First collection will be used for writing.");
50 using EntityMap = std::map<std::string, EntityBasePtr>;
58 virtual public PriorKnowledgeInterface,
66 return "PriorKnowledge";
68 void onInitComponent()
override;
69 void onConnectComponent()
override;
78 getConfigIdentifier()));
81 void clear(const ::Ice::Current& = Ice::emptyCurrent)
override;
84 return Component::getObjectAdapter();
88 PersistentObjectClassSegmentBasePrx getObjectClassesSegment(const ::Ice::Current& = Ice::emptyCurrent)
const override;
90 PersistentRelationSegmentBasePrx getRelationsSegment(const ::Ice::Current& = Ice::emptyCurrent)
const override;
92 GraphMemorySegmentBasePrx getGraphSegment(const ::Ice::Current&
c = Ice::emptyCurrent)
const override;
94 CommonStorageInterfacePrx getCommonStorage(const ::Ice::Current& = Ice::emptyCurrent)
const override;
96 bool hasGraphSegment(
const Ice::Current&
c = Ice::emptyCurrent)
const override;
98 bool isPriorCollection(const ::std::string& collNS, const ::Ice::Current& = Ice::emptyCurrent)
override;
107 void setSegmentReadCollections(
const PersistentEntitySegmentBasePtr& segmentPrx,
const NameList& collNameList);
111 std::string getMemoryName(
const Ice::Current&)
const override;
112 AbstractMemorySegmentPrx addGenericSegment(
const std::string& segmentName,
const Ice::Current&)
override;