Package org.openrdf.repository.sail

Examples of org.openrdf.repository.sail.SailRepository.initialize()


  {
    Collection<? extends Statement> entailedStatements = null;
    Collection<? extends Statement> expectedStatements = null;

    Repository repository = new SailRepository(sailStack);
    repository.initialize();

    RepositoryConnection con = repository.getConnection();

    // clear the input store
    con.clear();
View Full Code Here


      con.close();
    }

    // Upload output data
    Repository outputRepository = new SailRepository(new MemoryStore());
    outputRepository.initialize();
    con = outputRepository.getConnection();

    stream = getClass().getResourceAsStream(outputData);
    try {
      con.add(stream, outputData, RDFFormat.NTRIPLES);
View Full Code Here

  public void test()
    throws Exception
  {
    Repository rep1 = new SailRepository(new MemoryStore());
    rep1.initialize();

    RepositoryConnection con1 = rep1.getConnection();

    URL rdf = this.getClass().getResource("/testcases/rdfa-test.rdf");
View Full Code Here

    long before = con1.size();
    con1.close();

    Repository rep2 = new SailRepository(new MemoryStore());
    rep2.initialize();

    RepositoryConnection con2 = rep2.getConnection();

    con2.add(new StringReader(writer.toString()), rdf.toExternalForm(), rdfWriterFactory.getRDFFormat());
    long after = con2.size();
View Full Code Here

  @Override
  @Test
  public void testRemoveAll() throws Exception {
    Repository repo = new SailRepository(new MemoryStore());
    repo.initialize();
    RepositoryModelSet modelSet = new RepositoryModelSet(repo);
    modelSet.open();
    URI context1 = new URIImpl("uri:context1");
    URI context2 = new URIImpl("uri:context2");
    modelSet.addStatement(context1, new URIImpl("uri:r1"), new URIImpl(
View Full Code Here

    // create a Sail stack
    Sail sail = new MemoryStore();
    sail = new ForwardChainingRDFSInferencer(sail);
    // create a Repository
    Repository repository = new SailRepository(sail);
    repository.initialize();

    RepositoryConnection con = repository.getConnection();

    con.add(a, RDFS.SUBPROPERTYOF, b, defaultContext);
    con.add(b, RDFS.SUBPROPERTYOF, c, defaultContext);
View Full Code Here

    sail = new ForwardChainingRDFSPlusInverseInferencer(sail);

    // create a Repository
    Repository repository = new SailRepository(sail);
    try {
      repository.initialize();
    } catch (RepositoryException e) {
      throw new RuntimeException(e);
    }

    URI a = new URIImpl("urn:test:a");
View Full Code Here

    sail = new ForwardChainingRDFSPlusInverseInferencer(sail);

    // create a Repository
    Repository repository = new SailRepository(sail);
    try {
      repository.initialize();
    } catch (RepositoryException e) {
      throw new RuntimeException(e);
    }

    org.openrdf.model.URI a = new org.openrdf.model.impl.URIImpl(
View Full Code Here

    sail = new ForwardChainingRDFSPlusInverseInferencer(sail);

    // create a Repository
    Repository repository = new SailRepository(sail);
    try {
      repository.initialize();
    } catch (RepositoryException e) {
      throw new RuntimeException(e);
    }
   
    URI p = new URIImpl("urn:rel:p");
View Full Code Here

    sail = new ForwardChainingRDFSPlusInverseInferencer(sail);

    // create a Repository
    Repository repository = new SailRepository(sail);
    try {
      repository.initialize();
    } catch (RepositoryException e) {
      throw new RuntimeException(e);
    }
   
    URI a1 = new URIImpl("urn:name:a1");
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.