Package org.nuxeo.ecm.core.blob.binary
Class AbstractBinaryManager
java.lang.Object
org.nuxeo.ecm.core.blob.binary.AbstractBinaryManager
- All Implemented Interfaces:
BinaryManager
- Direct Known Subclasses:
CachingBinaryManager
,GridFSBinaryManager
,LocalBinaryManager
@Deprecated(since="2023.9")
public abstract class AbstractBinaryManager
extends Object
implements BinaryManager
Deprecated.
Abstract BinaryManager implementation that provides a few utilities
- Author:
- Florent Guillaume
-
Field Summary
Modifier and TypeFieldDescriptionDeprecated.static final int
Deprecated.static final String
Deprecated.protected BinaryManagerRootDescriptor
Deprecated.protected Pattern
Deprecated.Deprecated.protected BinaryGarbageCollector
Deprecated.static final int
Deprecated.static final String
Deprecated.static final int
Deprecated.since 11.1, unusedstatic final int
Deprecated.Deprecated.static final String
Deprecated.since 11.1, unusedstatic final int
Deprecated.since 11.1, unusedstatic final String
Deprecated.since 11.1, unusedstatic final int
Deprecated.since 11.1, unusedFields inherited from interface org.nuxeo.ecm.core.blob.binary.BinaryManager
PROP_KEY, PROP_PATH
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected void
Deprecated.protected abstract Binary
getBinary
(InputStream in) Deprecated.Creates a binary value from the given input stream.abstract Binary
Deprecated.Returns aBinary
corresponding to the given digest.Deprecated.Saves the given blob into aBinary
.protected String
Deprecated.Gets the default message digest to use to hash binaries.protected BinaryManagerRootDescriptor
getDescriptor
(File configFile) Deprecated.Gets existing descriptor or creates a default one.Deprecated.Returns the digest algorithm used to store and digest binaries.Deprecated.Returns the Binary Garbage Collector that can be used for this binary manager.void
initialize
(String blobProviderId, Map<String, String> properties) Deprecated.Initializes the binary manager.boolean
isValidDigest
(String digest) Deprecated.void
removeBinaries
(Collection<String> digests) Deprecated.Remove definitively a set of binariesprotected void
setDescriptor
(BinaryManagerRootDescriptor descriptor) Deprecated.protected String
storeAndDigest
(InputStream in, OutputStream out) Deprecated.static String
toHexString
(byte[] data) Deprecated.since 11.1, useHex.encodeHexString(byte[])
directlyMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.nuxeo.ecm.core.blob.binary.BinaryManager
close
-
Field Details
-
MD5_DIGEST
Deprecated.- See Also:
-
SHA1_DIGEST
Deprecated.since 11.1, unused- See Also:
-
SHA256_DIGEST
Deprecated.since 11.1, unused- See Also:
-
MD5_DIGEST_LENGTH
Deprecated.since 11.1, unused- See Also:
-
SHA1_DIGEST_LENGTH
Deprecated.since 11.1, unused- See Also:
-
SHA256_DIGEST_LENGTH
Deprecated.since 11.1, unused- See Also:
-
DIGESTS_BY_LENGTH
Deprecated.- Since:
- 7.4
-
DEFAULT_DIGEST
Deprecated.- See Also:
-
DEFAULT_DEPTH
public static final int DEFAULT_DEPTHDeprecated.- See Also:
-
blobProviderId
Deprecated. -
properties
Deprecated. -
descriptor
Deprecated. -
garbageCollector
Deprecated. -
digestPattern
Deprecated. -
MIN_BUF_SIZE
public static final int MIN_BUF_SIZEDeprecated.- See Also:
-
MAX_BUF_SIZE
public static final int MAX_BUF_SIZEDeprecated.- See Also:
-
-
Constructor Details
-
AbstractBinaryManager
public AbstractBinaryManager()Deprecated.
-
-
Method Details
-
initialize
Deprecated.Description copied from interface:BinaryManager
Initializes the binary manager.- Specified by:
initialize
in interfaceBinaryManager
- Parameters:
blobProviderId
- the blob provider id for this binary managerproperties
- initialization properties- Throws:
IOException
-
setDescriptor
Deprecated. -
getBinary
Deprecated.Creates a binary value from the given input stream.- Throws:
IOException
-
getBinary
Deprecated.Description copied from interface:BinaryManager
Saves the given blob into aBinary
.Returns a
Binary
representing the stream. TheBinary
includes a digest that is a sufficient representation to persist it.If the blob is a temporary
FileBlob
, then the temporary file may be reused as the final storage location after being moved.- Specified by:
getBinary
in interfaceBinaryManager
- Parameters:
blob
- the blob- Returns:
- the corresponding binary
- Throws:
IOException
-
getBinary
Deprecated.Description copied from interface:BinaryManager
Returns aBinary
corresponding to the given digest.A
null
is returned if the digest could not be found.- Specified by:
getBinary
in interfaceBinaryManager
- Parameters:
digest
- the digest, ornull
- Returns:
- the corresponding binary
-
removeBinaries
Deprecated.Description copied from interface:BinaryManager
Remove definitively a set of binaries- Specified by:
removeBinaries
in interfaceBinaryManager
- Parameters:
digests
- a set of digests, must not benull
.
-
getDescriptor
Deprecated.Gets existing descriptor or creates a default one.- Throws:
IOException
-
storeAndDigest
Deprecated.- Throws:
IOException
-
toHexString
Deprecated.since 11.1, useHex.encodeHexString(byte[])
directly -
computeDigestPattern
protected void computeDigestPattern()Deprecated. -
isValidDigest
Deprecated. -
getGarbageCollector
Deprecated.Description copied from interface:BinaryManager
Returns the Binary Garbage Collector that can be used for this binary manager.Several calls to this method will return the same GC, so that its status can be monitored using
BinaryGarbageCollector.isInProgress()
.- Specified by:
getGarbageCollector
in interfaceBinaryManager
- Returns:
- the binary GC
-
getDigestAlgorithm
Deprecated.Description copied from interface:BinaryManager
Returns the digest algorithm used to store and digest binaries.- Specified by:
getDigestAlgorithm
in interfaceBinaryManager
-
getDefaultDigestAlgorithm
Deprecated.Gets the default message digest to use to hash binaries.- Since:
- 6.0
-
BlobStoreBlobProvider
implementation instead