#include <heappagescanner.h>
Scanner class for scanning HeapPage.
◆ HeapPageScanner()
HeapPageScanner::HeapPageScanner |
( |
HeapPage * |
page | ) |
|
Constructor.
- Precondition
- Valid HeapPage* is provided as input. The given Page is pinned.
- Postcondition
- HeapPageScanner is constructed with initialized data members. page is still pinned.
- Parameters
-
◆ getNext()
SlotId HeapPageScanner::getNext |
( |
| ) |
|
Returns SlotId of the next valid slot.
- Precondition
- page is pinned.
- Postcondition
- SlotId of the next valid slot is returned. Current slot field is set to the next SlotId. Current slot field may be incremented by more than one. If the scanner reaches the end of the slot directory, INVALID_SLOT_ID is returned. page is still pinned.
- Returns
- Next valid SlotId. INVALID_SLOT_ID if the end of the Page is reached. page is still pinned.
◆ reset()
void HeapPageScanner::reset |
( |
HeapPage * |
page | ) |
|
Resets the scanner, so it could be used for another Page.
- Precondition
- The new Page is pinned.
- Postcondition
- page is set to the provided HeapPage* and current slot is reset to 0. The new Page is still pinned.
- Parameters
-
The documentation for this class was generated from the following file: