de.fuberlin.wiwiss.d2rq.find
Class CombinedTripleResultSet

java.lang.Object
  extended byde.fuberlin.wiwiss.d2rq.find.SQLResultSet
      extended byde.fuberlin.wiwiss.d2rq.find.CombinedTripleResultSet

public class CombinedTripleResultSet
extends SQLResultSet

Contains the result set from one SQL query and transforms it into triples. A triple is produced for TripleMaker in TripleMaker and each row in the result set.

History:
06-06-2004: Initial version of this class.
08-03-2004: Almost complete rewrite to make logic more explicit.

Version:
V0.2
Author:
Chris Bizer chris@bizer.de, Richard Cyganiak

Field Summary
private  com.hp.hpl.jena.graph.Triple[] chachedTriples
          The chached triples.
private  TripleQuery[] tripleMakers
          List of tripleMakers that are used on every row of the result set.
 
Fields inherited from class de.fuberlin.wiwiss.d2rq.find.SQLResultSet
columnNameNumberMap, currentRow, database, logger, numCols, protocol, queryHasBeenExecuted, separatorLogger, simulationMode, sql
 
Constructor Summary
CombinedTripleResultSet(java.lang.String SQL, java.util.Map columnNameNumberMap, Database db)
           
 
Method Summary
 boolean hasNext()
           
 com.hp.hpl.jena.graph.Triple[] next()
           
 void setTripleMakers(TripleQuery[] tripMakers)
           
 
Methods inherited from class de.fuberlin.wiwiss.d2rq.find.SQLResultSet
close, executeSQLQuery, nextRow
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

tripleMakers

private TripleQuery[] tripleMakers
List of tripleMakers that are used on every row of the result set.


chachedTriples

private com.hp.hpl.jena.graph.Triple[] chachedTriples
The chached triples. A value of null means there is no triple in the cache. A triple gets chached by hasNext() and is delivered afterwards by next().

Constructor Detail

CombinedTripleResultSet

public CombinedTripleResultSet(java.lang.String SQL,
                               java.util.Map columnNameNumberMap,
                               Database db)
Method Detail

setTripleMakers

public void setTripleMakers(TripleQuery[] tripMakers)

hasNext

public boolean hasNext()

next

public com.hp.hpl.jena.graph.Triple[] next()