@Override public BigdataStatement createStatement(Resource s, URI p, Value o, Resource c) { return valueFactory.createStatement(s, p, o, c); }
@Override public BigdataStatement createStatement(Resource s, URI p, Value o, Resource c) { return valueFactory.createStatement(s, p, o, c); }
@Override public BigdataStatement createStatement(Resource s, URI p, Value o, Resource c, StatementEnum type, boolean userFlag) { return valueFactory.createStatement(s, p, o, c, type, userFlag); }
@Override public BigdataStatement createStatement(Resource s, URI p, Value o, Resource c, StatementEnum type) { return valueFactory.createStatement(s, p, o, c, type, false); }
@Override public BigdataStatement createStatement(Resource s, URI p, Value o, Resource c, StatementEnum type) { return valueFactory.createStatement(s, p, o, c, type, false); }
@Override public BigdataStatement createStatement(Resource s, URI p, Value o, Resource c, StatementEnum type, boolean userFlag) { return valueFactory.createStatement(s, p, o, c, type, userFlag); }
@Override public BigdataStatement createStatement(Resource s, URI p, Value o) { return valueFactory.createStatement(s, p, o); }
@Override public BigdataStatement createStatement(Resource s, URI p, Value o) { return valueFactory.createStatement(s, p, o); }
public BigdataStatement toStatement(final BigdataValueFactory vf) { return vf.createStatement(s, p, o, c); }
public BigdataStatement toStatement(final BigdataValueFactory vf) { return vf.createStatement(s, p, o, c); }
/** * Per RDF Model Theory, new properties defined in the vocabulary will * always be of rdf:type rdf:Property and rdfs:Resource, and they will * always be subproperties of themselves. By defining these as axioms, we * save the inference engine some work by not having to keep track of * proving this information over and over again. */ protected void addAxioms(final Collection<BigdataStatement> axioms) { super.addAxioms(axioms); final BigdataValueFactory valueFactory = getValueFactory(); // axioms for #similarTo axioms.add( valueFactory.createStatement( SAMPLE.SIMILAR_TO, RDF.TYPE, RDF.PROPERTY, null, StatementEnum.Axiom)); axioms.add( valueFactory.createStatement( SAMPLE.SIMILAR_TO, RDF.TYPE, RDFS.RESOURCE, null, StatementEnum.Axiom)); axioms.add( valueFactory.createStatement( SAMPLE.SIMILAR_TO, RDFS.SUBPROPERTYOF, SAMPLE.SIMILAR_TO, null, StatementEnum.Axiom)); }
/** * Per RDF Model Theory, new properties defined in the vocabulary will * always be of rdf:type rdf:Property and rdfs:Resource, and they will * always be subproperties of themselves. By defining these as axioms, we * save the inference engine some work by not having to keep track of * proving this information over and over again. */ protected void addAxioms(final Collection<BigdataStatement> axioms) { super.addAxioms(axioms); final BigdataValueFactory valueFactory = getValueFactory(); // axioms for #similarTo axioms.add( valueFactory.createStatement( SAMPLE.SIMILAR_TO, RDF.TYPE, RDF.PROPERTY, null, StatementEnum.Axiom)); axioms.add( valueFactory.createStatement( SAMPLE.SIMILAR_TO, RDF.TYPE, RDFS.RESOURCE, null, StatementEnum.Axiom)); axioms.add( valueFactory.createStatement( SAMPLE.SIMILAR_TO, RDFS.SUBPROPERTYOF, SAMPLE.SIMILAR_TO, null, StatementEnum.Axiom)); }
private Statement makeStatement(final Resource id, final URI key, final Value value) { return m_om.getValueFactory().createStatement(id, key, value); }
private Statement makeStatement(final Resource id, final URI key, final Value value) { return m_om.getValueFactory().createStatement(id, key, value); }
public GPO(final IObjectManager om, final BNode id, final Statement stmt) { if (om == null) throw new IllegalArgumentException(); if (id == null) throw new IllegalArgumentException(); m_om = (ObjectMgrModel) om; m_id = om.getValueFactory().asValue(id); final BigdataStatement stmt2 = om.getValueFactory().createStatement( ((ObjectMgrModel)om).bestEffortIntern(stmt.getSubject()),// ((ObjectMgrModel)om).internKey(stmt.getPredicate()), // ((ObjectMgrModel)om).bestEffortIntern(stmt.getObject()) // ); this.m_stmt = stmt2; }
public GPO(final IObjectManager om, final BNode id, final Statement stmt) { if (om == null) throw new IllegalArgumentException(); if (id == null) throw new IllegalArgumentException(); m_om = (ObjectMgrModel) om; m_id = om.getValueFactory().asValue(id); final BigdataStatement stmt2 = om.getValueFactory().createStatement( ((ObjectMgrModel)om).bestEffortIntern(stmt.getSubject()),// ((ObjectMgrModel)om).internKey(stmt.getPredicate()), // ((ObjectMgrModel)om).bestEffortIntern(stmt.getObject()) // ); this.m_stmt = stmt2; }
@SuppressWarnings("unchecked") public void add(Resource s, URI p, Value o, Resource c, StatementEnum type) { final G stmt = (G) getValueFactory().createStatement(// (BigdataResource) convertValue(s), // (BigdataURI) convertValue(p), // convertValue(o), // (BigdataResource) convertValue(c), // type); add((F)stmt); }
@SuppressWarnings("unchecked") public void add(Resource s, URI p, Value o, Resource c, StatementEnum type) { final G stmt = (G) getValueFactory().createStatement(// (BigdataResource) convertValue(s), // (BigdataURI) convertValue(p), // convertValue(o), // (BigdataResource) convertValue(c), // type); add((F)stmt); }
public void test_context_stripping() { int capacity = 1; final AbstractTripleStore store = getStore(getProperties()); try { final BigdataValueFactory vf = store.getValueFactory(); final BigdataURI s = vf.createURI("http://example.com/s"); final BigdataURI p = vf.createURI("http://example.com/p"); final BigdataURI o = vf.createURI("http://example.com/o"); final BigdataURI c = vf.createURI("http://example.com/c"); final StatementBuffer<Statement> buffer = new StatementBuffer<Statement>( store, capacity); buffer.add(vf.createStatement(s, p, o, c, StatementEnum.Explicit)); // flush the buffer. buffer.flush(); assertTrue(store.hasStatement(s, p, o)); assertFalse(store.hasStatement(s, p, o, c)); } finally { store.__tearDownUnitTest(); } }
public void test_context_stripping() { int capacity = 1; final AbstractTripleStore store = getStore(getProperties()); try { final BigdataValueFactory vf = store.getValueFactory(); final BigdataURI s = vf.createURI("http://example.com/s"); final BigdataURI p = vf.createURI("http://example.com/p"); final BigdataURI o = vf.createURI("http://example.com/o"); final BigdataURI c = vf.createURI("http://example.com/c"); final StatementBuffer<Statement> buffer = new StatementBuffer<Statement>( store, capacity); buffer.add(vf.createStatement(s, p, o, c, StatementEnum.Explicit)); // flush the buffer. buffer.flush(); assertTrue(store.hasStatement(s, p, o)); assertFalse(store.hasStatement(s, p, o, c)); } finally { store.__tearDownUnitTest(); } }