org.openrdf.sesame.query
Class GraphQueryDuplicatesFilter

java.lang.Object
  extended byorg.openrdf.sesame.query.GraphQueryDuplicatesFilter
All Implemented Interfaces:
GraphQueryResultListener

public class GraphQueryDuplicatesFilter
extends Object
implements GraphQueryResultListener

A GraphQueryResultListener that filters any duplicates from the query results and forwards these filtered results to another GraphQueryResultListener.


Constructor Summary
GraphQueryDuplicatesFilter(GraphQueryResultListener l)
          Creates a new GraphQueryDuplicatesFilter.
 
Method Summary
 void endGraphQueryResult()
          Indicates the end of a graph-like query result.
 void namespace(String prefix, String name)
          Reports a namespace and its (preferred) prefix that might be used in the query result.
 void reportError(String msg)
          Reports an error that has occurred during the query evaluation.
 void startGraphQueryResult()
          Indicates the start of a graph-like query result.
 void triple(Resource subj, URI pred, Value obj)
          Delivers the next triple in the query result.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GraphQueryDuplicatesFilter

public GraphQueryDuplicatesFilter(GraphQueryResultListener l)
Creates a new GraphQueryDuplicatesFilter.

Parameters:
l - The GraphQueryResultListener that will receive the filtered query results.
Method Detail

startGraphQueryResult

public void startGraphQueryResult()
                           throws IOException
Description copied from interface: GraphQueryResultListener
Indicates the start of a graph-like query result.

Specified by:
startGraphQueryResult in interface GraphQueryResultListener
Throws:
IOException

endGraphQueryResult

public void endGraphQueryResult()
                         throws IOException
Description copied from interface: GraphQueryResultListener
Indicates the end of a graph-like query result.

Specified by:
endGraphQueryResult in interface GraphQueryResultListener
Throws:
IOException

namespace

public void namespace(String prefix,
                      String name)
               throws IOException
Description copied from interface: GraphQueryResultListener
Reports a namespace and its (preferred) prefix that might be used in the query result. Namespaces will be reported before the start of the query result as much as possible to accomodate listeners that need these mapping beforehand (like an RDF/XML document writer).

Specified by:
namespace in interface GraphQueryResultListener
Throws:
IOException

triple

public void triple(Resource subj,
                   URI pred,
                   Value obj)
            throws IOException
Description copied from interface: GraphQueryResultListener
Delivers the next triple in the query result.

Specified by:
triple in interface GraphQueryResultListener
Throws:
IOException

reportError

public void reportError(String msg)
                 throws IOException
Description copied from interface: GraphQueryResultListener
Reports an error that has occurred during the query evaluation.

Specified by:
reportError in interface GraphQueryResultListener
Throws:
IOException


Copyright © 2002-2006 Aduna BV, GNU LGPL License applies.