01: /*
02: * Copyright Aduna (http://www.aduna-software.com/) (c) 1997-2006.
03: *
04: * Licensed under the Aduna BSD-style license.
05: */
06: package org.openrdf.query;
07:
08: import java.util.List;
09:
10: /**
11: * An interface defining methods related to handling sequences of Solutions.
12: */
13: public interface TupleQueryResultHandler {
14:
15: /**
16: * Indicates the start of a sequence of Solutions. The supplied bindingNames
17: * are an indication of the values that are in the Solutions. For example, a
18: * SeRQL query like <tt>select X, Y from {X} P {Y} </tt> will have binding
19: * names <tt>X</tt> and <tt>Y</tt>.
20: *
21: * @param bindingNames
22: * An ordered set of binding names.
23: */
24: public void startQueryResult(List<String> bindingNames)
25: throws TupleQueryResultHandlerException;
26:
27: /**
28: * Indicates the end of a sequence of solutions.
29: */
30: public void endQueryResult()
31: throws TupleQueryResultHandlerException;
32:
33: /**
34: * Handles a solution.
35: */
36: public void handleSolution(BindingSet bindingSet)
37: throws TupleQueryResultHandlerException;
38: }
|