protected boolean hasStatement(final Resource subj, final URI pred, final Value obj, final boolean includeInferred, final Resource... contexts) throws RepositoryException { try { return m_repo.hasStatement(subj, pred, obj, includeInferred, contexts); } catch (Exception e) { throw new RepositoryException(e); } }
public void test_HASSTMT_p() throws Exception { doInsertbyURL("POST", packagePath + "test_estcard.ttl"); assertTrue(m_repo.hasStatement(null,// s RDF.TYPE,// p null,// o false// includeInferred // c )); assertFalse(m_repo.hasStatement(null,// s RDF.BAG,// p null,// o false// includeInferred // c )); }
/** * {@inheritDoc} * * @see <a href="http://trac.bigdata.com/ticket/1109"> hasStatements can * overestimate and ignores includeInferred (REST API) </a> */ @Override public boolean hasStatement(final Resource s, final URI p, final Value o, final boolean includeInferred, final Resource... c) throws RepositoryException { try { final RemoteRepository remote = repo.getRemoteRepository(); return remote.hasStatement(s, p, o, includeInferred, c); } catch (Exception ex) { throw new RepositoryException(ex); } }
public void test_HASSTMT_o() throws Exception { doInsertbyURL("POST", packagePath + "test_estcard.ttl"); assertTrue(m_repo.hasStatement(null,// s null,// p new LiteralImpl("Mike"),// o false // includeInferred // c )); assertFalse(m_repo.hasStatement(null,// s null,// p new LiteralImpl("Fred"),// o false // includeInferred // c )); }
public void test_HASSTMT_s() throws Exception { doInsertbyURL("POST", packagePath + "test_estcard.ttl"); assertTrue(m_repo.hasStatement(new URIImpl( "http://www.bigdata.com/Mike"),// s null,// p null,// o false// includeInferred )); assertFalse(m_repo.hasStatement(new URIImpl( "http://www.bigdata.com/Fred"),// s null,// p null,// o false// includeInferred )); }
protected boolean hasStatement(final Resource subj, final URI pred, final Value obj, final boolean includeInferred, final Resource... contexts) throws RepositoryException { try { return m_repo.hasStatement(subj, pred, obj, includeInferred, contexts); } catch (Exception e) { throw new RepositoryException(e); } }
public void test_HASSTMT_sp() throws Exception { doInsertbyURL("POST", packagePath + "test_estcard.ttl"); assertTrue(m_repo.hasStatement(new URIImpl( "http://www.bigdata.com/Mike"),// s RDFS.LABEL,// p null,// o false// includeInferred )); assertFalse(m_repo.hasStatement(new URIImpl( "http://www.bigdata.com/Mike"),// s RDF.BAG,// p null,// o false// includeInferred )); }
public void test_HASSTMT_po() throws Exception { doInsertbyURL("POST", packagePath + "test_estcard.ttl"); assertTrue( m_repo.hasStatement(null,// s, RDFS.LABEL,// p new LiteralImpl("Mike"),// o false // includeInferred // null // c )); assertFalse( m_repo.hasStatement(null,// s, RDFS.LABEL,// p new LiteralImpl("Fred"),// o false // includeInferred // null // c )); assertFalse( m_repo.hasStatement(null,// s, RDF.BAG,// p new LiteralImpl("Mike"),// o false // includeInferred // null // c )); }
public void test_HASSTMT_so() throws Exception { doInsertbyURL("POST", packagePath + "test_estcard.ttl"); assertTrue( m_repo.hasStatement(new URIImpl( "http://www.bigdata.com/Mike"),// s, RDF.TYPE,// p null,// o false // includeInferred // null // c )); assertFalse( m_repo.hasStatement(new URIImpl( "http://www.bigdata.com/Fred"),// s, RDF.TYPE,// p null,// o false // includeInferred // null // c )); assertFalse( m_repo.hasStatement(new URIImpl( "http://www.bigdata.com/Mike"),// s, RDF.BAG,// p null,// o false // includeInferred // null // c )); }
public void test_HASSTMT_p() throws Exception { doInsertbyURL("POST", packagePath + "test_estcard.ttl"); assertTrue(m_repo.hasStatement(null,// s RDF.TYPE,// p null,// o false// includeInferred // c )); assertFalse(m_repo.hasStatement(null,// s RDF.BAG,// p null,// o false// includeInferred // c )); }
assertTrue(m_repo.hasStatement(null,// s assertFalse(m_repo.hasStatement(null,// s
assertFalse(m_repo.hasStatement(OWL.EQUIVALENTCLASS, RDFS.SUBPROPERTYOF, RDFS.SUBCLASSOF, false// includeInferred )); assertTrue(m_repo.hasStatement(OWL.EQUIVALENTCLASS, RDFS.SUBPROPERTYOF, RDFS.SUBCLASSOF, true// includeInferred )); assertFalse(m_repo.hasStatement(OWL.EQUIVALENTCLASS, RDFS.SUBPROPERTYOF, RDFS.SUBCLASSOF, false// includeInferred )); assertTrue(m_repo.hasStatement(OWL.EQUIVALENTCLASS, RDFS.SUBPROPERTYOF, RDFS.SUBCLASSOF, true// includeInferred ));
public void test_HASSTMT_s() throws Exception { doInsertbyURL("POST", packagePath + "test_estcard.ttl"); assertTrue(m_repo.hasStatement(new URIImpl( "http://www.bigdata.com/Mike"),// s null,// p null,// o false// includeInferred )); assertFalse(m_repo.hasStatement(new URIImpl( "http://www.bigdata.com/Fred"),// s null,// p null,// o false// includeInferred )); }
public void test_HASSTMT_o() throws Exception { doInsertbyURL("POST", packagePath + "test_estcard.ttl"); assertTrue(m_repo.hasStatement(null,// s null,// p new LiteralImpl("Mike"),// o false // includeInferred // c )); assertFalse(m_repo.hasStatement(null,// s null,// p new LiteralImpl("Fred"),// o false // includeInferred // c )); }
public void test_HASSTMT_sp() throws Exception { doInsertbyURL("POST", packagePath + "test_estcard.ttl"); assertTrue(m_repo.hasStatement(new URIImpl( "http://www.bigdata.com/Mike"),// s RDFS.LABEL,// p null,// o false// includeInferred )); assertFalse(m_repo.hasStatement(new URIImpl( "http://www.bigdata.com/Mike"),// s RDF.BAG,// p null,// o false// includeInferred )); }
public void test_HASSTMT_po() throws Exception { doInsertbyURL("POST", packagePath + "test_estcard.ttl"); assertTrue( m_repo.hasStatement(null,// s, RDFS.LABEL,// p new LiteralImpl("Mike"),// o false // includeInferred // null // c )); assertFalse( m_repo.hasStatement(null,// s, RDFS.LABEL,// p new LiteralImpl("Fred"),// o false // includeInferred // null // c )); assertFalse( m_repo.hasStatement(null,// s, RDF.BAG,// p new LiteralImpl("Mike"),// o false // includeInferred // null // c )); }
public void test_HASSTMT_so() throws Exception { doInsertbyURL("POST", packagePath + "test_estcard.ttl"); assertTrue( m_repo.hasStatement(new URIImpl( "http://www.bigdata.com/Mike"),// s, RDF.TYPE,// p null,// o false // includeInferred // null // c )); assertFalse( m_repo.hasStatement(new URIImpl( "http://www.bigdata.com/Fred"),// s, RDF.TYPE,// p null,// o false // includeInferred // null // c )); assertFalse( m_repo.hasStatement(new URIImpl( "http://www.bigdata.com/Mike"),// s, RDF.BAG,// p null,// o false // includeInferred // null // c )); }
assertTrue(m_repo.hasStatement(null,// s assertFalse(m_repo.hasStatement(null,// s
assertFalse(m_repo.hasStatement(OWL.EQUIVALENTCLASS, RDFS.SUBPROPERTYOF, RDFS.SUBCLASSOF, false// includeInferred )); assertTrue(m_repo.hasStatement(OWL.EQUIVALENTCLASS, RDFS.SUBPROPERTYOF, RDFS.SUBCLASSOF, true// includeInferred )); assertFalse(m_repo.hasStatement(OWL.EQUIVALENTCLASS, RDFS.SUBPROPERTYOF, RDFS.SUBCLASSOF, false// includeInferred )); assertTrue(m_repo.hasStatement(OWL.EQUIVALENTCLASS, RDFS.SUBPROPERTYOF, RDFS.SUBCLASSOF, true// includeInferred ));