public class DfsGarbageCollector
extends java.lang.Object
Constructor and Description |
---|
DfsGarbageCollector(DfsRepository repository)
Initialize a garbage collector.
|
Modifier and Type | Method and Description |
---|---|
java.util.List<DfsPackDescription> |
getNewPacks() |
java.util.List<PackWriter.Statistics> |
getNewPackStatistics() |
PackConfig |
getPackConfig() |
java.util.List<DfsPackDescription> |
getSourcePacks() |
boolean |
pack(ProgressMonitor pm)
Create a single new pack file containing all of the live objects.
|
DfsGarbageCollector |
setPackConfig(PackConfig newConfig) |
public DfsGarbageCollector(DfsRepository repository)
repository
- repository objects to be packed will be read from.public PackConfig getPackConfig()
public DfsGarbageCollector setPackConfig(PackConfig newConfig)
newConfig
- the new configuration to use when creating the pack file.this
public boolean pack(ProgressMonitor pm) throws java.io.IOException
This method safely decides which packs can be expired after the new pack is created by validating the references have not been modified in an incompatible way.
pm
- progress monitor to receive updates on as packing may take a
while, depending on the size of the repository.java.io.IOException
- a new pack cannot be created.public java.util.List<DfsPackDescription> getSourcePacks()
public java.util.List<DfsPackDescription> getNewPacks()
public java.util.List<PackWriter.Statistics> getNewPackStatistics()
getNewPacks()
.Copyright © 2012. All Rights Reserved.