Resource s = leftSubject;
if (graph.isInstanceOf(pair.second.getObject(), L0.Literal)) {
Object value = null;
+ Resource type = null;
if (customValue != null)
value = customValue;
else if (graph.hasValue(pair.second.getObject())) {
value = graph.getValue(pair.second.getObject());
}
+ type = graph.getPossibleType(pair.second.getObject(), L0.Literal);
Resource pred = pair.second.getPredicate();
if (getChanges().getComparable().containsRight(pred))
pred = getChanges().getComparable().getLeft(pred);
if (value != null) {
graph.deny(s, pred);
- graph.claimLiteral(s, pred, value);
+ if (type != null) {
+ graph.claimLiteral(s, pred, type, value);
+ } else {
+ graph.claimLiteral(s, pred, value);
+ }
} else {
graph.deny(s,pred);
}