CLucene - a full-featured, c++ search engine
API Documentation


lucene::store::Directory Class Reference

A Directory is a flat list of files. More...

#include <Directory.h>

Inheritance diagram for lucene::store::Directory:

lucene::store::FSDirectory lucene::store::RAMDirectory

Public Member Functions

virtual ~Directory ()
char ** list () const
virtual void list (std::vector< std::string > *names) const =0
virtual bool fileExists (const char *name) const =0
virtual int64_t fileModified (const char *name) const =0
virtual int64_t fileLength (const char *name) const =0
virtual IndexInputopenInput (const char *name)=0
virtual IndexInputopenInput (const char *name, int32_t bufferSize)
virtual void touchFile (const char *name)=0
 Set the modified time of an existing file to now. */.
virtual bool deleteFile (const char *name, const bool throwError=true)
virtual void renameFile (const char *from, const char *to)=0
virtual IndexOutputcreateOutput (const char *name)=0
virtual LuceneLockmakeLock (const char *name)
virtual void clearLock (const char *name)
virtual void close ()=0
virtual TCHAR * toString () const =0
virtual const char * getDirectoryType () const =0
void setLockFactory (LockFactory *lockFactory)
LockFactorygetLockFactory ()
virtual TCHAR * getLockID ()

Protected Member Functions

 Directory ()
virtual bool doDeleteFile (const char *name)=0

Protected Attributes

LockFactorylockFactory

Detailed Description

A Directory is a flat list of files.

Files may be written once, when they are created. Once a file is created it may only be opened for read, or deleted. Random access is permitted both when reading and writing.

Direct i/o is not used directly, but rather all i/o is through this API. This permits things such as:


Constructor & Destructor Documentation

lucene::store::Directory::Directory (  )  [inline, protected]

virtual lucene::store::Directory::~Directory (  )  [virtual]


Member Function Documentation

virtual bool lucene::store::Directory::doDeleteFile ( const char *  name  )  [protected, pure virtual]

char** lucene::store::Directory::list (  )  const

virtual void lucene::store::Directory::list ( std::vector< std::string > *  names  )  const [pure virtual]

Implemented in lucene::store::FSDirectory.

virtual bool lucene::store::Directory::fileExists ( const char *  name  )  const [pure virtual]

virtual int64_t lucene::store::Directory::fileModified ( const char *  name  )  const [pure virtual]

virtual int64_t lucene::store::Directory::fileLength ( const char *  name  )  const [pure virtual]

virtual IndexInput* lucene::store::Directory::openInput ( const char *  name  )  [pure virtual]

virtual IndexInput* lucene::store::Directory::openInput ( const char *  name,
int32_t  bufferSize 
) [virtual]

Reimplemented in lucene::store::FSDirectory.

virtual void lucene::store::Directory::touchFile ( const char *  name  )  [pure virtual]

Set the modified time of an existing file to now. */.

Implemented in lucene::store::FSDirectory, and lucene::store::RAMDirectory.

virtual bool lucene::store::Directory::deleteFile ( const char *  name,
const bool  throwError = true 
) [virtual]

virtual void lucene::store::Directory::renameFile ( const char *  from,
const char *  to 
) [pure virtual]

virtual IndexOutput* lucene::store::Directory::createOutput ( const char *  name  )  [pure virtual]

virtual LuceneLock* lucene::store::Directory::makeLock ( const char *  name  )  [virtual]

virtual void lucene::store::Directory::clearLock ( const char *  name  )  [virtual]

virtual void lucene::store::Directory::close (  )  [pure virtual]

virtual TCHAR* lucene::store::Directory::toString (  )  const [pure virtual]

virtual const char* lucene::store::Directory::getDirectoryType (  )  const [pure virtual]

Implemented in lucene::store::FSDirectory.

void lucene::store::Directory::setLockFactory ( LockFactory lockFactory  ) 

LockFactory* lucene::store::Directory::getLockFactory (  ) 

virtual TCHAR* lucene::store::Directory::getLockID (  )  [virtual]


Field Documentation


The documentation for this class was generated from the following file:

clucene.sourceforge.net