@Override public void close() { dataset.close(); } }
@Override public void close() { if (this.dataset != null) { dataset.close(); } }
@Override protected void closeInternal() throws SQLException { try { if (this.ds != null) { ds.close(); ds = null; } } catch (Exception e) { throw new SQLException("Unexpected error closing a dataset backed connection", e); } finally { this.ds = null; } }
@Override protected void closeInternal() throws SQLException { try { if (this.ds != null) { ds.close(); ds = null; } } catch (Exception e) { throw new SQLException("Unexpected error closing a dataset backed connection", e); } finally { this.ds = null; } }
@Override public void tearDownTest() { if ( dataset != null ) { dataset.close() ; dataset = null ; } SystemARQ.UsePlainGraph = oldValueUsePlainGraph ; }
@Override public void tearDownTest() { if ( dataset != null ) { dataset.close() ; dataset = null ; } SystemARQ.UsePlainGraph = oldValueUsePlainGraph ; }
@Override public void tearDownTest() { if ( dataset != null ) { dataset.close() ; dataset = null ; } SystemARQ.UsePlainGraph = oldValueUsePlainGraph ; }
@Override public void tearDownTest() { if ( dataset != null ) { dataset.close() ; dataset = null ; } SystemARQ.UsePlainGraph = oldValueUsePlainGraph ; }
public void cancelMetricAssessment() throws LuzzuIOException { if(this.isInitalised == false) throw new ProcessorNotInitialised("Streaming will not start as processor has not been initalised"); forcedCancel = true; for (MetricProcess mp : lstMetricConsumers){ logger.info("Closing and clearing quads queue for {}", mp.getMetricName()); mp.closeAssessment(); } logger.info("Closing Iterators"); this.getMemoryModel().close(); } }
String directory = "D:\\Project\\Store_DB\\data1\\tdb"; Dataset dataset = TDBFactory.createDataset(directory); Model tdb = dataset.getDefaultModel(); // read the input file String source = "D:\\Project\\Store_DB\\tmp\\trail_1.rdf"; FileManager.get().readModel( tdb, source); dataset.commit();//INCLUDE THIS STAMEMENT tdb.close(); dataset.close();
@Override protected Dataset prepareDataset(Dataset ds) { if (currDataset != null) { currDataset.close(); } Dataset tdb = TDBFactory.createDataset(); TestUtils.copyDataset(ds, tdb, true); currDataset = tdb; return tdb; } }
@Override public Stream<Quad> stream() { final Dataset dataset = create(); try (final InputStream input = client.getObject(req).getObjectContent()) { RDFParser.source(input).lang(NQUADS).parse(dataset); } catch (final IOException ex) { dataset.close(); throw new RuntimeTrellisException("Error parsing input from S3", ex); } return rdf.asDataset(dataset).stream().map(Quad.class::cast).onClose(dataset::close); } }
/** * Cleans up after the tests by ensuring that the TDB dataset is closed */ @After public void cleanupTest() { if (currDataset != null) { currDataset.close(); } StoreConnection.expel(Location.mem(), true); }
@After public void after() { dataset.close() ; TDBInternal.expel(dataset.asDatasetGraph()); }
@AfterClass public static void teardown() { if (implJoin != null) { implJoin.close(); implJoin = null; } // Currently these optimizations are off by default Assert.assertFalse(ARQ.isFalse(ARQ.optFilterImplicitJoin)); Assert.assertFalse(ARQ.isFalse(ARQ.optImplicitLeftJoin)); }
private void createTest(String filename, Resource type) { Object thing = AssemblerUtils.build(filename, type) ; assertTrue(thing instanceof Dataset) ; Dataset ds = (Dataset)thing ; assertTrue(ds.asDatasetGraph() instanceof DatasetGraphTransaction) ; assertTrue(ds.supportsTransactions()) ; ds.close(); }
private void createTest(String filename, Resource type) { Object thing = AssemblerUtils.build(filename, type) ; assertTrue(thing instanceof Dataset) ; Dataset ds = (Dataset)thing ; assertTrue(ds.asDatasetGraph() instanceof DatasetGraphSwitchable) ; assertTrue(ds.supportsTransactions()) ; ds.close() ; }
private void createTest(String filename, Resource type) { Object thing = AssemblerUtils.build(filename, type) ; assertTrue(thing instanceof Dataset) ; Dataset ds = (Dataset)thing ; assertTrue(ds.asDatasetGraph() instanceof DatasetGraphSwitchable) ; assertTrue(ds.supportsTransactions()) ; ds.close() ; }
private void createTest(String filename, Resource type) { Object thing = AssemblerUtils.build(filename, type) ; assertTrue(thing instanceof Dataset) ; Dataset ds = (Dataset)thing ; assertTrue(ds.asDatasetGraph() instanceof DatasetGraphTransaction) ; assertTrue(ds.supportsTransactions()) ; ds.close(); }