From 6bda937a1f922195fb233aa36b81ffc4ea6dd84b Mon Sep 17 00:00:00 2001 From: David Hook Date: Fri, 28 Aug 2020 16:41:59 +1000 Subject: added IDigestFactory --- crypto/src/crypto/IDigestFactory.cs | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 crypto/src/crypto/IDigestFactory.cs (limited to 'crypto/src') diff --git a/crypto/src/crypto/IDigestFactory.cs b/crypto/src/crypto/IDigestFactory.cs new file mode 100644 index 000000000..b37bab90e --- /dev/null +++ b/crypto/src/crypto/IDigestFactory.cs @@ -0,0 +1,24 @@ +namespace Org.BouncyCastle.Crypto +{ + /// + /// Base interface for operator factories that create stream-based digest calculators. + /// + /// The algorithm details/parameter type for the digest factory. + public interface IDigestFactory + { + /// The algorithm details object for calculators made by this factory. + A AlgorithmDetails { get ; } + + /// Return the size of the digest associated with this factory. + /// The length of the digest produced by this calculators from this factory in bytes. + int DigestLength { get; } + + /// + /// Create a stream calculator for the digest associated with this factory. The stream + /// calculator is used for the actual operation of entering the data to be digested + /// and producing the digest block. + /// + /// A calculator producing an IBlockResult with the final digest in it. + IStreamCalculator CreateCalculator(); + } +} -- cgit 1.5.1