Package com.hp.hpl.jena.tdb.store

Examples of com.hp.hpl.jena.tdb.store.DatasetGraphTDB


   
    @Override
    protected void exec()
    {
        // This formats the location correctly.
        DatasetGraphTDB dsg = SetupTDB.buildDataset(location) ;

        // so close indexes and the prefix table.
        dsg.getTripleTable().getNodeTupleTable().getTupleTable().close();
        dsg.getQuadTable().getNodeTupleTable().getTupleTable().close();
        // Later - attach prefix table to parser.
        dsg.getPrefixes().close() ;

        ProgressLogger monitorTotal = new ProgressLogger(cmdLog, "tuples", BulkLoader.DataTickPoint,BulkLoader.superTick) ;
        monitorTotal.start() ;

        DataBag<Tuple<Long>> outputTriples = new MultiThreadedSortedDataBag<Tuple<Long>>(getThresholdPolicy(tripleSerializationFactory), new TripleSerializationFactory(), comparator);
View Full Code Here


    }

    @Override
    protected void exec()
    {
        DatasetGraphTDB dsg = getDatasetGraphTDB() ;
        NodeTable nodeTable = dsg.getTripleTable().getNodeTupleTable().getNodeTable() ;
        Iterator<String> iter = super.getPositional().iterator() ;
        if ( ! iter.hasNext() )
        {
            System.err.println("No node ids") ;
            return ;
View Full Code Here

    }

    @Override
    protected void exec()
    {
        DatasetGraphTDB dsg = super.getDatasetGraphTDB() ;
        JournalControl.recovery(dsg) ;
    }
View Full Code Here

        List<String> tripleIndexes = Arrays.asList(Names.tripleIndexes) ;
        List<String> quadIndexes = Arrays.asList(Names.quadIndexes) ;
        Location loc = modLocation.getLocation() ;
       
        StoreConnection sConn = StoreConnection.make(loc) ;
        DatasetGraphTDB dsg = sConn.getBaseDataset() ;
        NodeTable nodeTable = dsg.getQuadTable().getNodeTupleTable().getNodeTable() ;
        dump(System.out, nodeTable) ;
    }
View Full Code Here

    @Override
    protected void exec()
    {
        // This formats the location correctly.
        // But we're not really interested in it all.
        DatasetGraphTDB dsg = DatasetBuilderStd.build(location) ;
       
        // so close indexes and the prefix table.
        dsg.getTripleTable().getNodeTupleTable().getTupleTable().close();
        dsg.getQuadTable().getNodeTupleTable().getTupleTable().close();
        // Later - attach prefix table to parser.
        dsg.getPrefixes().close() ;
       
        ProgressLogger monitor = new ProgressLogger(cmdLog, "Data", BulkLoader.DataTickPoint,BulkLoader.superTick) ;
        OutputStream outputTriples = null ;
        OutputStream outputQuads = null ;
       
View Full Code Here

    public final static RecordFactory nodeRecordFactory = new RecordFactory(LenNodeHash, SizeOfNodeId) ;
   
    /** Create a TDB graph using a specifc index builder - mainly for testing */
    public static GraphTriplesTDB createGraph(IndexBuilder indexBuilder, Location location)
    {
        DatasetGraphTDB ds = _createDatasetGraph(indexBuilder, location, tripleIndexes, quadIndexes) ;
        return (GraphTriplesTDB)ds.getDefaultGraph() ;
   
View Full Code Here

        NodeTable nodeTable = NodeTableFactory.create(indexBuilder, location) ;
        TripleTable triples = createTripleTable(indexBuilder, nodeTable, location, graphIndexDesc, policy) ;
        QuadTable quads = createQuadTable(indexBuilder, nodeTable, location, quadIndexDesc, policy) ;
        @SuppressWarnings("deprecation")
        DatasetPrefixesTDB prefixes = DatasetPrefixesTDB.create(indexBuilder, location, policy) ;
        return new DatasetGraphTDB(triples, quads, prefixes, chooseOptimizer(location), null) ;
    }
View Full Code Here

        cleanup() ;
    }
   
    private void setupPlain() {
        // Make without transactions.
        DatasetGraphTDB dsg = com.hp.hpl.jena.tdb.sys.TDBMaker._createDatasetGraph(location) ;
        dsg.add(quad1) ;
        dsg.close() ;
        // Normally done via close() but be explicit.
        com.hp.hpl.jena.tdb.sys.TDBMaker.releaseDataset(dsg) ;
        return ;
    }
View Full Code Here

    }
   
    @Test
    public void testPlain() {
        assertEquals (3, countRDFNodes()) ;
        DatasetGraphTDB dsg = com.hp.hpl.jena.tdb.sys.TDBMaker._createDatasetGraph(location) ;
        assertTrue(dsg.contains(quad1)) ;
        dsg.add(quad2) ;
        assertTrue(dsg.contains(quad2)) ;
        dsg.close() ;
        com.hp.hpl.jena.tdb.sys.TDBMaker.releaseDataset(dsg) ;
        assertEquals (4, countRDFNodes()) ;
    }
View Full Code Here

        dsgR1.end() ;

        dsgW2.commit() ;
        dsgW2.end() ;

        DatasetGraphTDB dsg = sConn.getBaseDataset() ;
        assertTrue(dsg.contains(q1)) ;
        assertTrue(dsg.contains(q2)) ;
    }
View Full Code Here

TOP

Related Classes of com.hp.hpl.jena.tdb.store.DatasetGraphTDB

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.