public class DefaultBinaryManager extends LocalBinaryManager implements BinaryManagerStreamSupport
A garbage collection is needed to purge unused binaries.
The format of the binaries directory is:
LocalBinaryManager
instead to make use of a
scrambler.Modifier and Type | Class and Description |
---|---|
static class |
AbstractBinaryManager.NullBinaryScrambler
A
BinaryScrambler that does nothing. |
static class |
AbstractBinaryManager.ScrambledBinary
A
Binary that is unscrambled on read using a
BinaryScrambler . |
static class |
AbstractBinaryManager.ScrambledFileInputStream
A
FileInputStream that is unscrambled on read using a
BinaryScrambler . |
static class |
AbstractBinaryManager.ScrambledStreamSource
A
FileSource that is unscrambled on read using a
BinaryScrambler . |
LocalBinaryManager.DefaultBinaryGarbageCollector
Modifier and Type | Field and Description |
---|---|
static int |
DEFAULT_DEPTH |
static String |
DEFAULT_DIGEST |
static int |
MAX_BUF_SIZE |
static int |
MIN_BUF_SIZE |
CONFIG_FILE, DATA, DEFAULT_PATH, TMP
Constructor and Description |
---|
DefaultBinaryManager() |
Modifier and Type | Method and Description |
---|---|
Binary |
getBinary(FileSource source) |
BinaryGarbageCollector |
getGarbageCollector()
Returns the Binary Garbage Collector that can be used for this binary
manager.
|
static String |
toHexString(byte[] data) |
getBinary, getBinary, getFileForDigest, getStorageDir, initialize, touch
public static final String DEFAULT_DIGEST
public static final int DEFAULT_DEPTH
public static final int MIN_BUF_SIZE
public static final int MAX_BUF_SIZE
public Binary getBinary(FileSource source) throws IOException
getBinary
in interface BinaryManagerStreamSupport
IOException
public static String toHexString(byte[] data)
public BinaryGarbageCollector getGarbageCollector()
BinaryManager
Several calls to this method will return the same GC, so that its status
can be monitored using BinaryGarbageCollector.isInProgress()
.
getGarbageCollector
in interface BinaryManager
Copyright © 2013 Nuxeo SA. All Rights Reserved.