final IV<?, ?> iv = bnode.getIV();
private boolean isInvalidBlankNode(Value v) { if (v instanceof BigdataBNode && ((BigdataBNode)v).isStatementIdentifier()) { return false; } else { return v instanceof BNode; } }
if (bnode.isStatementIdentifier()) continue; if (bnode.getIV() != null) continue;
final public boolean equals(final BNode o) { if (this == o) return true; if (o == null) return false; if ((o instanceof BigdataValue) // && isRealIV() && ((BigdataValue)o).isRealIV() && ((BigdataValue) o).getValueFactory() == getValueFactory()) { return getIV().equals(((BigdataValue) o).getIV()); } else if ((o instanceof BigdataBNode) // && isStatementIdentifier() && ((BigdataBNode)o).isStatementIdentifier() ) { return getStatement().equals(((BigdataBNode) o).getStatement()); } return id.equals(o.getID()); }
final BigdataStatement stmt = bnode.getStatement(); bnode.setStatement(valueFactory.createStatement( (BigdataResource) getDistinctTerm(stmt.getSubject(), true), (BigdataURI) getDistinctTerm(stmt.getPredicate(), true), final String id = bnode.getID(); if (bnode.getIV() == null) {
s1.setStatementIdentifier(true); final ISPO spo = new SPO(s0);//SAP.getIV(), bought.getIV(), sybase.getIV(), // null/* NO CONTEXT */, StatementEnum.Explicit); s1.setIV(new SidIV<BigdataBNode>(spo));
/** * Returns the bnode representation of this IV, useful for serialization * formats such as RDF/XML. See {@link #bnodeId()}. */ @SuppressWarnings("unchecked") @Override public V asValue(final LexiconRelation lex) { if (bnode == null) { bnode = (V) lex.getValueFactory().createBNode(getID()); bnode.setIV(this); bnode.setStatementIdentifier(true); final BigdataResource c = spo.c() != null ? (BigdataResource) spo.c().asValue(lex) : null; bnode.setStatement(lex.getValueFactory().createStatement( (BigdataResource) spo.s().asValue(lex), (BigdataURI) spo.p().asValue(lex), (BigdataValue) spo.o().asValue(lex), c)); } return bnode; }
public V asValue(final LexiconRelation lex) { V bnode = getValueCache(); if (bnode == null) { final ValueFactory f = lex.getValueFactory(); bnode = (V) f.createBNode(stringValue()); bnode.setIV(this); setValue(bnode); } return bnode; }
protected void writeSid(final BigdataBNode sid) throws IOException, QueryResultHandlerException { jg.writeStartObject(); jg.writeStringField("type", BigdataSPARQLResultsJSONParser.SID); final BigdataStatement stmt = sid.getStatement(); jg.writeFieldName(BigdataSPARQLResultsJSONParser.SUBJECT); writeValue(stmt.getSubject()); jg.writeFieldName(BigdataSPARQLResultsJSONParser.PREDICATE); writeValue(stmt.getPredicate()); jg.writeFieldName(BigdataSPARQLResultsJSONParser.OBJECT); writeValue(stmt.getObject()); if (stmt.getContext() != null) { jg.writeFieldName(BigdataSPARQLResultsJSONParser.CONTEXT); writeValue(stmt.getContext()); } jg.writeEndObject(); }
s1.setStatementIdentifier(true); final ISPO spo = new SPO(s0);//SAP.getIV(), bought.getIV(), sybase.getIV(), // null/* NO CONTEXT */, StatementEnum.Explicit); s1.setIV(new SidIV<BigdataBNode>(spo));
/** * Returns the bnode representation of this IV, useful for serialization * formats such as RDF/XML. See {@link #bnodeId()}. */ @SuppressWarnings("unchecked") @Override public V asValue(final LexiconRelation lex) { if (bnode == null) { bnode = (V) lex.getValueFactory().createBNode(getID()); bnode.setIV(this); bnode.setStatementIdentifier(true); final BigdataResource c = spo.c() != null ? (BigdataResource) spo.c().asValue(lex) : null; bnode.setStatement(lex.getValueFactory().createStatement( (BigdataResource) spo.s().asValue(lex), (BigdataURI) spo.p().asValue(lex), (BigdataValue) spo.o().asValue(lex), c)); } return bnode; }
public V asValue(final LexiconRelation lex) { V bnode = getValueCache(); if (bnode == null) { final ValueFactory f = lex.getValueFactory(); bnode = (V) f.createBNode(stringValue()); bnode.setIV(this); setValue(bnode); } return bnode; }
if (bnode.isStatementIdentifier()) continue; if (bnode.getIV() != null) continue;
final BigdataStatement stmt = bnode.getStatement(); bnode.setStatement(valueFactory.createStatement( (BigdataResource) getDistinctTerm(stmt.getSubject(), true), (BigdataURI) getDistinctTerm(stmt.getPredicate(), true), final String id = bnode.getID(); if (bnode.getIV() == null) {
final public boolean equals(final BNode o) { if (this == o) return true; if (o == null) return false; if ((o instanceof BigdataValue) // && isRealIV() && ((BigdataValue)o).isRealIV() && ((BigdataValue) o).getValueFactory() == getValueFactory()) { return getIV().equals(((BigdataValue) o).getIV()); } else if ((o instanceof BigdataBNode) // && isStatementIdentifier() && ((BigdataBNode)o).isStatementIdentifier() ) { return getStatement().equals(((BigdataBNode) o).getStatement()); } return id.equals(o.getID()); }
protected void writeSid(final BigdataBNode sid) throws IOException, QueryResultHandlerException { jg.writeStartObject(); jg.writeStringField("type", BigdataSPARQLResultsJSONParser.SID); final BigdataStatement stmt = sid.getStatement(); jg.writeFieldName(BigdataSPARQLResultsJSONParser.SUBJECT); writeValue(stmt.getSubject()); jg.writeFieldName(BigdataSPARQLResultsJSONParser.PREDICATE); writeValue(stmt.getPredicate()); jg.writeFieldName(BigdataSPARQLResultsJSONParser.OBJECT); writeValue(stmt.getObject()); if (stmt.getContext() != null) { jg.writeFieldName(BigdataSPARQLResultsJSONParser.CONTEXT); writeValue(stmt.getContext()); } jg.writeEndObject(); }
s1.setStatementIdentifier(true); final ISPO spo = new SPO(SAP.getIV(), bought.getIV(), sybase.getIV(), s1.setIV(new SidIV<BigdataBNode>(spo));