@Override public BigdataBNodeImpl createBNode(final String id) { return new BigdataBNodeImpl(this, id); }
@Override final public boolean equals(final Object o) { if (!(o instanceof BNode)) return false; return equals((BNode) o); }
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()); }
if (sid.getStatement() != null) { sid.setStatement(reifiedStmt.toStatement(valueFactory));
@Override public IV getIV() { if (super.iv == null && sid != null) { // if (sid.getSubject() == this || sid.getObject() == this) // throw new UnificationException("illegal self-referential sid"); if (selfRef) { throw new UnificationException("illegal self-referential sid"); } // temporarily set it to true while we get the IVs on the sid selfRef = true; final IV s = sid.s(); final IV p = sid.p(); final IV o = sid.o(); // if we make it to here then we have a fully grounded sid selfRef = false; if (s != null && p != null && o != null) { setIV(new SidIV(new SPO(s, p, o))); } } return super.iv; }
ivToEncode = new FullyInlineUnicodeBNodeIV<>(valAsBNode.getID());
if (sid.getStatement() != null) { sid.setStatement(reifiedStmt.toStatement(valueFactory));
@Override public IV getIV() { if (super.iv == null && sid != null) { // if (sid.getSubject() == this || sid.getObject() == this) // throw new UnificationException("illegal self-referential sid"); if (selfRef) { throw new UnificationException("illegal self-referential sid"); } // temporarily set it to true while we get the IVs on the sid selfRef = true; final IV s = sid.s(); final IV p = sid.p(); final IV o = sid.o(); // if we make it to here then we have a fully grounded sid selfRef = false; if (s != null && p != null && o != null) { setIV(new SidIV(new SPO(s, p, o))); } } return super.iv; }
ivToEncode = new FullyInlineUnicodeBNodeIV<>(valAsBNode.getID());
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()); }
@Override public BigdataBNodeImpl createBNode(final String id) { return new BigdataBNodeImpl(this, id); }
@Override final public boolean equals(final Object o) { if (!(o instanceof BNode)) return false; return equals((BNode) o); }
@Override public BigdataBNodeImpl createBNode(final BigdataStatement stmt) { // Subject, predicate, object and context should be processed to use the target value factory // See https://jira.blazegraph.com/browse/BLZG-1875 final BigdataResource originalS = stmt.getSubject(); final BigdataURI originalP = stmt.getPredicate(); final BigdataValue originalO = stmt.getObject(); final BigdataResource originalC = stmt.getContext(); final BigdataResource s = asValue(originalS); final BigdataURI p = asValue(originalP); final BigdataValue o = asValue(originalO); final BigdataResource c = asValue(originalC); final BigdataStatement effectiveStmt; if (originalS != s || originalP != p || originalO != o || originalC != c) { effectiveStmt = new BigdataStatementImpl(s, p, o, c, stmt.getStatementType(), stmt.getUserFlag()); } else { effectiveStmt = stmt; } return new BigdataBNodeImpl(this, nextID(), effectiveStmt); }
@Override public BigdataBNodeImpl createBNode(final BigdataStatement stmt) { // Subject, predicate, object and context should be processed to use the target value factory // See https://jira.blazegraph.com/browse/BLZG-1875 final BigdataResource originalS = stmt.getSubject(); final BigdataURI originalP = stmt.getPredicate(); final BigdataValue originalO = stmt.getObject(); final BigdataResource originalC = stmt.getContext(); final BigdataResource s = asValue(originalS); final BigdataURI p = asValue(originalP); final BigdataValue o = asValue(originalO); final BigdataResource c = asValue(originalC); final BigdataStatement effectiveStmt; if (originalS != s || originalP != p || originalO != o || originalC != c) { effectiveStmt = new BigdataStatementImpl(s, p, o, c, stmt.getStatementType(), stmt.getUserFlag()); } else { effectiveStmt = stmt; } return new BigdataBNodeImpl(this, nextID(), effectiveStmt); }