Interface ChecksumAlgorithmFactorySelector
- All Known Implementing Classes:
DefaultChecksumAlgorithmFactorySelector
public interface ChecksumAlgorithmFactorySelector
Component performing selection of
ChecksumAlgorithmFactory
based on known factory names.
Note: this component is NOT meant to be implemented or extended by client, is exposed ONLY to make clients
able to get ChecksumAlgorithmFactory
instances.- Since:
- 1.8.0
- Restriction:
- This interface is not intended to be extended by clients.
- Restriction:
- This interface is not intended to be implemented by clients.
-
Method Summary
Modifier and TypeMethodDescriptionReturns a collection of supported algorithms.Returns factory for given algorithm name, or throws if algorithm not supported.selectList
(Collection<String> algorithmNames) Returns a list of factories for given algorithm names in order as collection is ordered, or throws if any of the algorithm name is not supported.
-
Method Details
-
select
Returns factory for given algorithm name, or throws if algorithm not supported.- Throws:
IllegalArgumentException
- if asked algorithm name is not supported.
-
selectList
Returns a list of factories for given algorithm names in order as collection is ordered, or throws if any of the algorithm name is not supported. The returned list has equal count of elements as passed in collection of names, and if names contains duplicated elements, the returned list of algorithms will have duplicates as well.- Throws:
IllegalArgumentException
- if any asked algorithm name is not supported.NullPointerException
- if passed in list of names isnull
.- Since:
- 1.9.0
-
getChecksumAlgorithmFactories
Returns a collection of supported algorithms. This set represents ALL the algorithms supported by Resolver, and is NOT in any relation to given repository layout used checksums, returned by methodRepositoryLayout.getChecksumAlgorithmFactories()
(in fact, is super set of it).
-