On 26/12/17 14:24, Claude Warren wrote:
if this method does not have to account for null node values then
node.isVariable() would suffice.
On Tue, Dec 26, 2017 at 1:46 PM, Claude Warren <[email protected]> wrote:
QueryTripleIterator at line 87 calls Var.isVar(node) which throws an
exception if the node is a Node_Variable.
QueryIterTriplePattern?
Or some class you have created?
QueryIterTriplePattern is used for solving a single step of a basic
graph pattern.
Var is a subclass of Node_Variable. ARQ works with Var, not
Node_Variable.
The exception captures an internal error condition.
How did it get in?
But based code following line 87
I think that Node_Variable should be accepted.
Andy
{noformat}
private static Node substitute(Node node, Binding binding)
{
if ( Var.isVar(node) ) // <---- line 87
{
Node x = binding.get(Var.alloc(node)) ;
if ( x != null )
return x ;
}
return node ;
}
{noformat}
I think that perhaps the if check should be
if (node instanceof Node_Variable)
As with a lot of this code I am not certain and want to verify before I
change anything.
Claude
--
I like: Like Like - The likeliest place on the web
<http://like-like.xenei.com>
LinkedIn: http://www.linkedin.com/in/claudewarren