org.apache.activemq.kaha.impl.index
Class IndexManager

java.lang.Object
  extended by org.apache.activemq.kaha.impl.index.IndexManager

public final class IndexManager
extends Object

Optimized Store reader


Field Summary
static String NAME_PREFIX
           
 
Constructor Summary
IndexManager(File directory, String name, String mode, DataManager redoLog, AtomicLong storeSize)
           
 
Method Summary
 void close()
           
 IndexItem createNewIndex()
           
 boolean delete()
           
 void force()
           
 void freeIndex(IndexItem item)
           
 IndexItem getIndex(long offset)
           
 FileLock getLock()
           
protected  void initialize()
           
 boolean isEmpty()
           
 void redo(RedoStoreIndexItem redo)
           
 IndexItem refreshIndex(IndexItem item)
           
 void setLength(long value)
           
 long size()
           
 void storeIndex(IndexItem index)
           
 String toString()
           
 void updateIndexes(IndexItem index)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

NAME_PREFIX

public static final String NAME_PREFIX
See Also:
Constant Field Values
Constructor Detail

IndexManager

public IndexManager(File directory,
                    String name,
                    String mode,
                    DataManager redoLog,
                    AtomicLong storeSize)
             throws IOException
Throws:
IOException
Method Detail

isEmpty

public boolean isEmpty()

getIndex

public IndexItem getIndex(long offset)
                   throws IOException
Throws:
IOException

refreshIndex

public IndexItem refreshIndex(IndexItem item)
                       throws IOException
Throws:
IOException

freeIndex

public void freeIndex(IndexItem item)
               throws IOException
Throws:
IOException

storeIndex

public void storeIndex(IndexItem index)
                throws IOException
Throws:
IOException

updateIndexes

public void updateIndexes(IndexItem index)
                   throws IOException
Throws:
IOException

redo

public void redo(RedoStoreIndexItem redo)
          throws IOException
Throws:
IOException

createNewIndex

public IndexItem createNewIndex()
                         throws IOException
Throws:
IOException

close

public void close()
           throws IOException
Throws:
IOException

force

public void force()
           throws IOException
Throws:
IOException

delete

public boolean delete()
               throws IOException
Throws:
IOException

size

public final long size()

setLength

public void setLength(long value)

getLock

public FileLock getLock()
                 throws IOException
Throws:
IOException

toString

public String toString()
Overrides:
toString in class Object

initialize

protected void initialize()
                   throws IOException
Throws:
IOException


Copyright © 2005-2012 The Apache Software Foundation. All Rights Reserved.