#if !BESTHTTP_DISABLE_ALTERNATE_SSL && (!UNITY_WEBGL || UNITY_EDITOR)
#pragma warning disable
using System;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto
{
/// Base interface for a message digest.
public interface IDigest
{
/// The algorithm name.
string AlgorithmName { get; }
/// Return the size, in bytes, of the digest produced by this message digest.
/// the size, in bytes, of the digest produced by this message digest.
int GetDigestSize();
/// Return the size, in bytes, of the internal buffer used by this digest.
/// the size, in bytes, of the internal buffer used by this digest.
int GetByteLength();
/// Update the message digest with a single byte.
/// the input byte to be entered.
void Update(byte input);
/// Update the message digest with a block of bytes.
/// the byte array containing the data.
/// the offset into the byte array where the data starts.
/// the length of the data.
void BlockUpdate(byte[] input, int inOff, int inLen);
#if NETCOREAPP2_1_OR_GREATER || NETSTANDARD2_1_OR_GREATER || _UNITY_2021_2_OR_NEWER_
/// Update the message digest with a span of bytes.
/// the span containing the data.
void BlockUpdate(ReadOnlySpan input);
#endif
/// Close the digest, producing the final digest value.
/// This call leaves the digest reset.
/// the byte array the digest is to be copied into.
/// the offset into the byte array the digest is to start at.
/// the number of bytes written
int DoFinal(byte[] output, int outOff);
#if NETCOREAPP2_1_OR_GREATER || NETSTANDARD2_1_OR_GREATER || _UNITY_2021_2_OR_NEWER_
/// Close the digest, producing the final digest value.
/// This call leaves the digest reset.
/// the span the digest is to be copied into.
/// the number of bytes written
int DoFinal(Span output);
#endif
/// Reset the digest back to its initial state.
void Reset();
}
}
#pragma warning restore
#endif