Interface HashHandler
- All Known Implementing Classes:
HashHandler.BuildHandler
,HashHandler.ProbeHandler
public interface HashHandler
Callback from generated hash table code.
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic class
When building, this operation is never invoked.static class
When probing, these operations are never invoked. -
Method Summary
Modifier and TypeMethodDescriptionvoid
doMainFound
(int tableLocation, int chunkPosition) Called after a value is found in the main hash tablevoid
doMainInsert
(int tableLocation, int chunkPosition) Called after a value is inserted into the main hash tablevoid
doMissing
(int chunkPosition) Called during probe when a value is not found in main or overflow.void
doMoveMain
(int oldTableLocation, int newTableLocation) Called during rehash when a value is moved in the main tablevoid
doOverflowFound
(int overflowLocation, int chunkPosition) Called after a value is found in the overflow hash tablevoid
doOverflowInsert
(int overflowLocation, int chunkPosition) Called after a value is inserted into the overflow hash tablevoid
doPromoteOverflow
(int overflowLocation, int mainInsertLocation) Called during rehash when a value is promoted from overflow to the main tablevoid
onNextChunk
(int size) Called when the next chunk of data is being processed in build or probe.
-
Method Details
-
doMainInsert
void doMainInsert(int tableLocation, int chunkPosition) Called after a value is inserted into the main hash table- Parameters:
tableLocation
- location of insertionchunkPosition
- the position in the chunk
-
doMainFound
void doMainFound(int tableLocation, int chunkPosition) Called after a value is found in the main hash table- Parameters:
tableLocation
- location in the tablechunkPosition
- the position in the chunk
-
doOverflowInsert
void doOverflowInsert(int overflowLocation, int chunkPosition) Called after a value is inserted into the overflow hash table- Parameters:
overflowLocation
- location of insertionchunkPosition
- the position in the chunk
-
doOverflowFound
void doOverflowFound(int overflowLocation, int chunkPosition) Called after a value is found in the overflow hash table- Parameters:
overflowLocation
- location in the overflow tablechunkPosition
- the position in the chunk
-
doMoveMain
void doMoveMain(int oldTableLocation, int newTableLocation) Called during rehash when a value is moved in the main table- Parameters:
oldTableLocation
- the old location in the main tablenewTableLocation
- the new location in the main table
-
doPromoteOverflow
void doPromoteOverflow(int overflowLocation, int mainInsertLocation) Called during rehash when a value is promoted from overflow to the main table- Parameters:
overflowLocation
- the old location in the overflow tablemainInsertLocation
- the new location in the main table
-
onNextChunk
void onNextChunk(int size) Called when the next chunk of data is being processed in build or probe.- Parameters:
size
- the size of the next chunk
-
doMissing
void doMissing(int chunkPosition) Called during probe when a value is not found in main or overflow.- Parameters:
chunkPosition
- the position in the chunk
-