Interface PageReadWriteManager
-
- All Known Subinterfaces:
IgnitePageStoreManager
- All Known Implementing Classes:
DefragmentationPageReadWriteManager,FilePageStoreManager,PageReadWriteManagerImpl
public interface PageReadWriteManager
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description longallocatePage(int grpId, int partId, byte flags)Allocates a page for the given page space.voidread(int grpId, long pageId, ByteBuffer pageBuf, boolean keepCrc)Reads a page for the given cache ID.PageStorewrite(int grpId, long pageId, ByteBuffer pageBuf, int tag, boolean calculateCrc)Writes the page for the given cache ID.
-
-
-
Method Detail
-
read
void read(int grpId, long pageId, ByteBuffer pageBuf, boolean keepCrc) throws IgniteCheckedExceptionReads a page for the given cache ID. Cache ID may be0if the page is a meta page.- Parameters:
grpId- Cache group ID.pageId- PageID to read.pageBuf- Page buffer to write to.keepCrc- Keep CRC flag.- Throws:
IgniteCheckedException- If failed to read the page.
-
write
PageStore write(int grpId, long pageId, ByteBuffer pageBuf, int tag, boolean calculateCrc) throws IgniteCheckedException
Writes the page for the given cache ID. Cache ID may be0if the page is a meta page.- Parameters:
grpId- Cache group ID.pageId- Page ID.pageBuf- Page buffer to write.- Throws:
IgniteCheckedException- If failed to write page.
-
allocatePage
long allocatePage(int grpId, int partId, byte flags) throws IgniteCheckedExceptionAllocates a page for the given page space.- Parameters:
grpId- Cache group ID.partId- Partition ID. Used only ifflagsis equal toPageIdAllocator.FLAG_DATA.flags- Page allocation flags.- Returns:
- Allocated page ID.
- Throws:
IgniteCheckedException- If IO exception occurred while allocating a page ID.
-
-