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

java.lang.Object
  extended by org.apache.activemq.kaha.impl.index.IndexItem
All Implemented Interfaces:
Item, StoreEntry

public class IndexItem
extends Object
implements Item, StoreEntry

A an Item with a relative position and location to other Items in the Store


Field Summary
static int INDEX_SIZE
           
static int INDEXES_ONLY_SIZE
           
protected  long offset
           
 
Fields inherited from interface org.apache.activemq.kaha.impl.data.Item
ACTIVE, FREE, LOCATION_SIZE, MAGIC, POSITION_NOT_SET
 
Constructor Summary
IndexItem()
          Default Constructor
 
Method Summary
 boolean equals(Object obj)
           
 StoreLocation getKeyDataItem()
           
 int getKeyFile()
           
 int getKeySize()
           
 long getNextItem()
           
 long getOffset()
           
 StoreLocation getValueDataItem()
           
 int getValueFile()
           
 long getValueOffset()
           
 int getValueSize()
           
 int hashCode()
           
 void read(DataInput dataIn)
           
 void setKeyData(StoreLocation item)
           
 void setKeySize(int keySize)
           
 void setNextItem(long newNextEntry)
           
 void setOffset(long offset)
           
 void setPreviousItem(long newPrevEntry)
           
 void setValueData(StoreLocation item)
           
 void setValueOffset(long valueOffset)
           
 void setValueSize(int valueSize)
           
 String toString()
           
 void write(DataOutput dataOut)
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

INDEX_SIZE

public static final int INDEX_SIZE
See Also:
Constant Field Values

INDEXES_ONLY_SIZE

public static final int INDEXES_ONLY_SIZE
See Also:
Constant Field Values

offset

protected long offset
Constructor Detail

IndexItem

public IndexItem()
Default Constructor

Method Detail

getKeyDataItem

public StoreLocation getKeyDataItem()
Specified by:
getKeyDataItem in interface StoreEntry
Returns:
See Also:
StoreEntry.getKeyDataItem()

getValueDataItem

public StoreLocation getValueDataItem()
Specified by:
getValueDataItem in interface StoreEntry
Returns:
See Also:
StoreEntry.getValueDataItem()

setValueData

public void setValueData(StoreLocation item)

setKeyData

public void setKeyData(StoreLocation item)

write

public void write(DataOutput dataOut)
           throws IOException
Parameters:
dataOut -
Throws:
IOException

read

public void read(DataInput dataIn)
          throws IOException
Parameters:
dataIn -
Throws:
IOException

setPreviousItem

public void setPreviousItem(long newPrevEntry)
Parameters:
newPrevEntry -

setNextItem

public void setNextItem(long newNextEntry)
Parameters:
newNextEntry -

getNextItem

public long getNextItem()
Specified by:
getNextItem in interface StoreEntry
Returns:
See Also:
StoreEntry.getNextItem()

getKeyFile

public int getKeyFile()
Specified by:
getKeyFile in interface StoreEntry
Returns:
See Also:
StoreEntry.getKeyFile()

getValueFile

public int getValueFile()
Specified by:
getValueFile in interface StoreEntry
Returns:
See Also:
StoreEntry.getValueFile()

getValueOffset

public long getValueOffset()
Specified by:
getValueOffset in interface StoreEntry
Returns:
See Also:
StoreEntry.getValueOffset()

setValueOffset

public void setValueOffset(long valueOffset)
Parameters:
valueOffset - The valueOffset to set.

getOffset

public long getOffset()
Specified by:
getOffset in interface StoreEntry
Returns:
See Also:
StoreEntry.getOffset()

setOffset

public void setOffset(long offset)
Parameters:
offset - The offset to set.

getKeySize

public int getKeySize()
Specified by:
getKeySize in interface StoreEntry
Returns:
See Also:
StoreEntry.getKeySize()

setKeySize

public void setKeySize(int keySize)

getValueSize

public int getValueSize()
Specified by:
getValueSize in interface StoreEntry
Returns:
See Also:
StoreEntry.getValueSize()

setValueSize

public void setValueSize(int valueSize)

toString

public String toString()
Overrides:
toString in class Object
Returns:
print of 'this'

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object


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