de.fuberlin.wiwiss.d2rq
Class CachingGraphD2RQ

java.lang.Object
  extended by com.hp.hpl.jena.graph.impl.GraphBase
      extended by de.fuberlin.wiwiss.d2rq.GraphD2RQ
          extended by de.fuberlin.wiwiss.d2rq.CachingGraphD2RQ
All Implemented Interfaces:
com.hp.hpl.jena.graph.Graph, com.hp.hpl.jena.graph.GraphAdd, com.hp.hpl.jena.graph.impl.GraphWithPerform

public class CachingGraphD2RQ
extends GraphD2RQ

A GraphD2RQ that caches the results of the most recently performed queries on an LRU basis.

Version:
$Id: CachingGraphD2RQ.java,v 1.1 2006/09/11 23:22:25 cyganiak Exp $
Author:
Holger Knublauch (holger@topquadrant.com)

Field Summary
 
Fields inherited from class com.hp.hpl.jena.graph.impl.GraphBase
bulkHandler, closed, gem, pm, queryHandler, reifier, style
 
Fields inherited from interface com.hp.hpl.jena.graph.Graph
emptyGraph
 
Constructor Summary
CachingGraphD2RQ(com.hp.hpl.jena.rdf.model.Model mapModel, String baseURIForData)
           
 
Method Summary
 void clearCache()
          Clears the current cache.
 com.hp.hpl.jena.util.iterator.ExtendedIterator graphBaseFind(com.hp.hpl.jena.graph.TripleMatch m)
          Overloaded to reuse and update the cache.
 
Methods inherited from class de.fuberlin.wiwiss.d2rq.GraphD2RQ
classMapInventory, classMapNames, classMapNamesForResource, close, connect, getCapabilities, initInventory, isUsingD2RQQueryHandler, queryHandler, setUsingD2RQQueryHandler
 
Methods inherited from class com.hp.hpl.jena.graph.impl.GraphBase
add, checkOpen, contains, contains, containsByFind, delete, dependsOn, find, find, forTestingOnly_graphBaseFind, getBulkUpdateHandler, getEventManager, getPrefixMapping, getReifier, getTransactionHandler, graphBaseContains, graphBaseFind, graphBaseSize, isClosed, isEmpty, isIsomorphicWith, notifyAdd, notifyDelete, performAdd, performDelete, reifierContains, reifierSize, reifierTriples, size, toString, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface com.hp.hpl.jena.graph.Graph
contains, contains, delete, dependsOn, find, find, getBulkUpdateHandler, getEventManager, getPrefixMapping, getReifier, getTransactionHandler, isClosed, isEmpty, isIsomorphicWith, size
 
Methods inherited from interface com.hp.hpl.jena.graph.GraphAdd
add
 

Constructor Detail

CachingGraphD2RQ

public CachingGraphD2RQ(com.hp.hpl.jena.rdf.model.Model mapModel,
                        String baseURIForData)
                 throws D2RQException
Throws:
D2RQException
Method Detail

clearCache

public void clearCache()
Clears the current cache. This can be used in case the database has been changed.


graphBaseFind

public com.hp.hpl.jena.util.iterator.ExtendedIterator graphBaseFind(com.hp.hpl.jena.graph.TripleMatch m)
Overloaded to reuse and update the cache.

Overrides:
graphBaseFind in class GraphD2RQ