@NotStorableClass public class GarbageCandidateRecordManager extends Object
Constructor and Description |
---|
GarbageCandidateRecordManager(StoreHeader storeHeader,
HeapRecordableManager heapRecordableManager,
HelperBinaryConversion helperBinaryConversion) |
Modifier and Type | Method and Description |
---|---|
boolean |
addCandidate(DataRecordIdentifier dataRecordIdentifier)
add a data record identifier garbage candidate to the list ( sorted red
black tree )
|
boolean |
containsCandidate(DataRecordIdentifier dataRecordIdentifier)
FOR TEST ONLY
|
void |
getAllDataRecordIdentifiers(Set<DataRecordIdentifier> setToUpdate) |
List<DataRecordIdentifierRBTNode> |
getCandidate()
for test purpose only
|
int |
getNumberOfGarbageCandidate()
get number of garbage candidate in the list
|
boolean |
isEmpty() |
DataRecordIdentifier |
pollFirstCandidate()
Retrieves and removes the first garbage candidate record identifier
|
boolean |
removeCandidate(DataRecordIdentifier dataRecordIdentifier)
remove a data record identifier of garbage candidate from the list if
exist.
|
public GarbageCandidateRecordManager(StoreHeader storeHeader, HeapRecordableManager heapRecordableManager, HelperBinaryConversion helperBinaryConversion)
public boolean addCandidate(DataRecordIdentifier dataRecordIdentifier) throws GarbageException
dataRecordIdentifier
- data record identifier of garbage candidateGarbageException
public boolean removeCandidate(DataRecordIdentifier dataRecordIdentifier) throws GarbageException
dataRecordIdentifier
- data record identifier for candidate to remove if existGarbageException
public DataRecordIdentifier pollFirstCandidate() throws GarbageException
GarbageException
public int getNumberOfGarbageCandidate() throws GarbageException
GarbageException
public boolean isEmpty() throws GarbageException
GarbageException
@Fortest public boolean containsCandidate(DataRecordIdentifier dataRecordIdentifier) throws GarbageException
dataRecordIdentifier
- GarbageException
@Fortest public List<DataRecordIdentifierRBTNode> getCandidate() throws GarbageException
GarbageException
public void getAllDataRecordIdentifiers(Set<DataRecordIdentifier> setToUpdate) throws GarbageException
GarbageException
Copyright © 2007-2012 Luc Peuvrier. All Rights Reserved.