/** * Close this {@link Query}, and the underlying {@link Answer} objects. */ public void close() throws TuplesException { answer.close(); answer = null; if (mutableVariableList != null) { for (SelectElement v: mutableVariableList) { if (v instanceof AggregateFunction) { ((AggregateFunction)v).getQuery().close(); } } } }
variables[i] = ((ConstantValue) element).getVariable(); } else if (element instanceof AggregateFunction) { variables[i] = ((AggregateFunction) element).getVariable(); } else { throw new IllegalArgumentException("Unknown type in SELECT clause: " + element.getClass());