|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.netbeans.mdr.persistence.btreeimpl.btreeindex.BtreeCacheSource
public class BtreeCacheSource
In-memory page source for unit testing
| Constructor Summary | |
|---|---|
BtreeCacheSource(MDRCache cache,
int pageSize,
BtreeStorage storage)
|
|
| Method Summary | |
|---|---|
void |
dirtyPage(BtreePage page)
Notify the BtreePageSource that the caller is going to modify this page. |
java.lang.String |
getMofidPrefix()
Get the prefix for this repository |
long |
getNextMofid()
get the next unique ID for this repository |
BtreePage |
getPage(byte[] pageId,
Btree btree)
Retrieve a page. |
EntryTypeInfo |
getPageIdInfo()
Get an EntryTypeInfo for the datatype of this BtreePageSource's page IDs. |
int |
getPageIdLength()
Returns the length of a page ID. |
int |
getPageSize()
Returns the size of a page. |
BtreePage |
getRootPage(Btree btree)
Retrieve the root page for this btree. |
BtreeStorage |
getStorage()
|
boolean |
isNoPage(byte[] pageId)
Test whether the passed-in pageId contains the special value noPageId |
BigKeyPage |
newBigKeyPage(Btree btree)
Creates a new oversize-key page and returns it. |
BtreePage |
newPage(Btree btree)
Creates a new page and returns it. |
void |
setNoPage(byte[] pageId)
Set the passed-in pageId to contain the special value noPageId |
void |
unpinPage(BigKeyPage page)
Notify the BtreePageSource that the caller is done using this page. |
void |
unpinPage(BtreePage page)
Notify the BtreePageSource that the caller is done using this page. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public BtreeCacheSource(MDRCache cache,
int pageSize,
BtreeStorage storage)
throws StorageException
StorageException| Method Detail |
|---|
public BtreePage getPage(byte[] pageId,
Btree btree)
throws StorageException
BtreePageSource
getPage in interface BtreePageSourcepageId - byte array buffer containing pageIdbtree - btree to which the page belongs
StorageException
public BigKeyPage newBigKeyPage(Btree btree)
throws StorageException
BtreePageSource
newBigKeyPage in interface BtreePageSourcebtree - btree to which the page belongs
StorageException
public BtreePage newPage(Btree btree)
throws StorageException
BtreePageSource
newPage in interface BtreePageSourcebtree - btree to which the page belongs
StorageExceptionpublic void unpinPage(BtreePage page)
BtreePageSource
unpinPage in interface BtreePageSourcepage - BtreePagepublic void unpinPage(BigKeyPage page)
BtreePageSource
unpinPage in interface BtreePageSourcepage - BigKeyPage
public void dirtyPage(BtreePage page)
throws StorageException
BtreePageSource
dirtyPage in interface BtreePageSourcepage - BtreePage
StorageException
public BtreePage getRootPage(Btree btree)
throws StorageException
BtreePageSource
getRootPage in interface BtreePageSourcebtree - Btree
StorageExceptionpublic EntryTypeInfo getPageIdInfo()
BtreePageSource
getPageIdInfo in interface BtreePageSourcepublic int getPageIdLength()
BtreePageSource
getPageIdLength in interface BtreePageSourcepublic int getPageSize()
BtreePageSource
getPageSize in interface BtreePageSourcepublic void setNoPage(byte[] pageId)
setNoPage in interface BtreePageSourcepageId - byte array to be filled inpublic boolean isNoPage(byte[] pageId)
isNoPage in interface BtreePageSourcepublic long getNextMofid()
MofidGenerator
getNextMofid in interface MofidGeneratorpublic java.lang.String getMofidPrefix()
MofidGenerator
getMofidPrefix in interface MofidGeneratorpublic BtreeStorage getStorage()
getStorage in interface BtreePageSource
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||