Esempio n. 1
0
 public KEStore(ITripleStoreProvider storeProvider, ITripleStoreFactory factory, IVisibilityManager visibilityManager)
 {
     StoreProvider     = storeProvider;
     Factory           = factory;
     VisibilityManager = visibilityManager;
     MappedStore       = new MemoryStore();
     Mapper            = new KEMapper(this);
     Vocab             = new KEVocab(factory);
 }
Esempio n. 2
0
        public ICollection <IStatement> Import(Store store)
        {
            cleanupBNodes(store);
            KEMapper mapper = new KEMapper(this);
            ICollection <IStatement> statements = new List <IStatement>();

            foreach (SemWeb.Statement statement in store.Select(SemWeb.SelectFilter.All))
            {
                statements.Add(mapper.toKE(statement));
            }
            Graph.BeginUpdate();
            Graph.Add(statements);
            Graph.EndUpdate();
            return(statements);
        }