- All Known Implementing Classes:
public interface BinaryGarbageCollectorA Garbage Collector for a
First, inform the GC that it is started by calling
Then for all binaries to mark, call
Finally when all binaries have been marked, call
stop(boolean)to delete the non-marked binaries.
getStatus()returns information about the binaries remaining and those that have been GCed.
All Methods Instance Methods Abstract Methods Modifier and Type Method Description
getId()Gets a unique identifier for this garbage collector.
getStatus()Gets the status of the binaries to GC and of those that won't be.
isInProgress()Checks if a GC is in progress.
mark(String digest)Marks a binary as being in use.
start()Starts the garbage collection process.
stop(boolean delete)Stops the garbage collection process and deletes all binaries that have not been marked (sweep).
getIdGets a unique identifier for this garbage collector. Two garbage collectors that would impact the same files must have the same identifier.
- a unique identifier
void start()Starts the garbage collection process.
After this, all active binaries must be fed to the
markMarks a binary as being in use.
digest- the binary's digest
void stop(boolean delete)Stops the garbage collection process and deletes all binaries that have not been marked (sweep).
trueif actual deletion must be performed,
falseif the binaries to delete should simply be counted in the status
getStatusGets the status of the binaries to GC and of those that won't be.
- the status