net.sf.lucis.core.impl
Class FSStore<T>

java.lang.Object
  extended by net.sf.lucis.core.impl.FSStore<T>
Type Parameters:
T - Checkpoint type.
All Implemented Interfaces:
DirectoryProvider, Store<T>

public class FSStore<T>
extends java.lang.Object
implements Store<T>

File system-based store.

Author:
Andres Rodriguez

Constructor Summary
FSStore(Checkpoint<T> serializer, java.lang.String indexDir)
           
 
Method Summary
 T getCheckpoint()
          Returns the current checkpoint.
 org.apache.lucene.store.Directory getDirectory()
          Returns the underlying directory.
 java.lang.Object getVersion()
          Returns the current version.
 void setCheckpoint(T checkpoint)
          Sets the current checkpoint.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FSStore

public FSStore(Checkpoint<T> serializer,
               java.lang.String indexDir)
Method Detail

getDirectory

public org.apache.lucene.store.Directory getDirectory()
Description copied from interface: DirectoryProvider
Returns the underlying directory.

Specified by:
getDirectory in interface DirectoryProvider
Returns:
The directory used by the index.

getCheckpoint

public T getCheckpoint()
Description copied from interface: Store
Returns the current checkpoint.

Specified by:
getCheckpoint in interface Store<T>
Returns:
The current checkpoint.

setCheckpoint

public void setCheckpoint(T checkpoint)
Description copied from interface: Store
Sets the current checkpoint.

Specified by:
setCheckpoint in interface Store<T>
Parameters:
checkpoint - Checkpoint to set. Must not be null.

getVersion

public java.lang.Object getVersion()
Description copied from interface: DirectoryProvider
Returns the current version. Version objects are only tested for equality so no ordering is required. However they MUST obey equals and hashCode contracts.

Specified by:
getVersion in interface DirectoryProvider


Copyright © 2009. All Rights Reserved.