edu.utdallas.paged.mem.disk
Class PagedGraphTripleStoreDiskBase

java.lang.Object
  extended by edu.utdallas.paged.mem.disk.PagedGraphTripleStoreDiskBase
Direct Known Subclasses:
PagedGraphTripleStoreDiskGeneric, PagedGraphTripleStoreDiskReasoning, PagedGraphTripleStoreDiskSpecific, PagedGraphTripleStoreDiskUpdate

public abstract class PagedGraphTripleStoreDiskBase
extends java.lang.Object

An abstract class that defines the basic methods for querying the lucene indexes

Author:
vaibhav

Nested Class Summary
static class PagedGraphTripleStoreDiskBase.Singleton
          Singleton class to generate single objects of the index reader and the searcher to be used for searching the lucene index
 
Field Summary
 int increment
          The increment keeps track of the chunk that is being read from the lucene index, is used for a select * type of query
 int incrementThreshold
          A variable to keep track of the indices read at a time from the lucene index
 int lineIndex
          The current position from where the Lucene index is being read
 edu.utdallas.paged.mem.PagedGraphTripleStoreBase p
          This is an instance of the base class
 boolean readLine
          A variable to keep track of whether a triple was successfully read from the lucene index
 com.hp.hpl.jena.graph.TripleMatch tripleMatch
          The triple pattern to be found in the lucene index
 
Constructor Summary
PagedGraphTripleStoreDiskBase(com.hp.hpl.jena.graph.TripleMatch tm)
          Constructor
PagedGraphTripleStoreDiskBase(com.hp.hpl.jena.graph.TripleMatch tm, edu.utdallas.paged.mem.PagedGraphTripleStoreBase p)
          Constructor
 
Method Summary
 void add(com.hp.hpl.jena.graph.Triple t)
          Method to add the triple to the jena structure, for the update triples case
abstract  java.util.Iterator find()
          Method to find a triple pattern in the lucene index
abstract  java.util.Iterator read(java.lang.String searchString, java.lang.String fileString)
          Method that checks the lucene index for a string
static java.lang.String removePunctuation(java.lang.String input)
          Method to remove punctuations
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

lineIndex

public int lineIndex
The current position from where the Lucene index is being read


increment

public int increment
The increment keeps track of the chunk that is being read from the lucene index, is used for a select * type of query


tripleMatch

public com.hp.hpl.jena.graph.TripleMatch tripleMatch
The triple pattern to be found in the lucene index


readLine

public boolean readLine
A variable to keep track of whether a triple was successfully read from the lucene index


p

public edu.utdallas.paged.mem.PagedGraphTripleStoreBase p
This is an instance of the base class


incrementThreshold

public int incrementThreshold
A variable to keep track of the indices read at a time from the lucene index

Constructor Detail

PagedGraphTripleStoreDiskBase

public PagedGraphTripleStoreDiskBase(com.hp.hpl.jena.graph.TripleMatch tm,
                                     edu.utdallas.paged.mem.PagedGraphTripleStoreBase p)
Constructor

Parameters:
tm - - the triple pattern we are looking for
p - - the triple store base instance

PagedGraphTripleStoreDiskBase

public PagedGraphTripleStoreDiskBase(com.hp.hpl.jena.graph.TripleMatch tm)
Constructor

Parameters:
tm - - the triple pattern we are looking for
Method Detail

add

public void add(com.hp.hpl.jena.graph.Triple t)
Method to add the triple to the jena structure, for the update triples case

Parameters:
t - - the triple to add

removePunctuation

public static java.lang.String removePunctuation(java.lang.String input)
Method to remove punctuations

Parameters:
input - - the input string
Returns:
the string with punctuation removed

read

public abstract java.util.Iterator read(java.lang.String searchString,
                                        java.lang.String fileString)
Method that checks the lucene index for a string

Parameters:
searchString - - the strinng we are looking for
fileString - - the index we want to check
Returns:
a null iterator or an iterator that contains the triples that match the triple pattern we are looking for

find

public abstract java.util.Iterator find()
Method to find a triple pattern in the lucene index

Returns:
a null iterator or an iterator that contains the triples that match the triple pattern we are looking for