Exemplo n.º 1
0
        //// Идея хорошая, но надо менять схему реализации
        //private GroupedEntities getable;
        //private Dictionary<int, object[]> geHash;

        public TripleStoreInt(string path)
        {
            this.path = path;
            InitTypes();
            otriples    = new PaCell(tp_otriple_seq, path + "otriples.pac", false);
            otriples_op = new PaCell(tp_otriple_seq, path + "otriples_op.pac", false);
            dtriples    = new PaCell(tp_dtriple_seq, path + "dtriples.pac", false);
            dtriples_sp = new PaCell(tp_dtriple_spf, path + "dtriples_spf.pac", false);

            scale = new ScaleCell(path);
            if (!otriples.IsEmpty)
            {
                OpenCreateIndexes();
            }
            ewt = new EntitiesWideTable(path, new DiapasonScanner <int>[]
            {
                new DiapasonScanner <int>(otriples, ent => (int)((object[])ent.Get())[0]),
                new DiapasonScanner <int>(otriples_op, ent => (int)((object[])ent.Get())[2]),
                new DiapasonScanner <int>(dtriples_sp, ent => (int)((object[])ent.Get())[0])
            });
            ewtHash = new EntitiesMemoryHashTable(ewt);
            ewtHash.Load();

            //getable = new GroupedEntities(path); // Это хорошая идея, но нужно менять схему реализации
            //getable.CheckGroupedEntities();
            //geHash = getable.GroupedEntitiesHash();
        }
Exemplo n.º 2
0
        public SGraph(string path, Uri uri)
        {
            this.path    = path;
            Uri          = uri;
            otriples     = new PaCell(tp_otriple_seq, path + "otriples.pac", false);
            dtriples     = new PaCell(tp_dtriple_spf, path + "dtriples.pac", false); // Временно выведена в переменные класса, открывается при инициализации
            dataCell     = new PaCell(tp_data_seq, path + "data.pac", false);
            entitiesTree = new PxCell(tp_entitiesTree, path + "entitiesTree.pxc", false);

            namespaceMaper = new NamespaceMapCoding(new StringIntMD5RAMUnsafe(path));
            scale          = new ScaleCell(path);
        }
Exemplo n.º 3
0
 protected RDFIntStoreAbstract(IStringIntCoding entityCoding, PredicatesCoding predicatesCoding, NameSpaceStore nameSpaceStore, LiteralStoreAbstract literalStore,
                               ScaleCell scale)
 {
     this.literalStore     = literalStore;
     this.entityCoding     = entityCoding;
     this.nameSpaceStore   = nameSpaceStore;
     this.predicatesCoding = predicatesCoding;
     this.scale            = scale;
     if (!scale.Cell.IsEmpty)
     {
         scale.CalculateRange();
     }
 }