[]
Represents a delegate used to calculate the hash over data. The data can be represented by an array of bytes or by a System.IO.Stream.
Outputs the hash value and the hash algorithm OID.
public delegate void TimeStamp.HashDelegate(byte[] dataToHash, Stream streamToHash, out byte[] hash, out OID hashAlgorithmOid)
dataToHash
byte[]The byte array containing the data. If null, streamToHash
will be used.
streamToHash
System.IO.StreamThe stream containing the data. If null, dataToHash
will be used.
hash
byte[]OUT: The data hash value.
hashAlgorithmOid
OIDOUT: The hash algorithm OID.
public HashDelegate(object @object, IntPtr method)
object
objectmethod
System.IntPtrpublic virtual IAsyncResult BeginInvoke(byte[] dataToHash, Stream streamToHash, out byte[] hash, out OID hashAlgorithmOid, AsyncCallback callback, object @object)
dataToHash
byte[]streamToHash
System.IO.Streamhash
byte[]hashAlgorithmOid
OIDcallback
System.AsyncCallbackobject
objectpublic virtual void EndInvoke(out byte[] hash, out OID hashAlgorithmOid, IAsyncResult result)
hash
byte[]hashAlgorithmOid
OIDresult
System.IAsyncResultpublic virtual void Invoke(byte[] dataToHash, Stream streamToHash, out byte[] hash, out OID hashAlgorithmOid)
dataToHash
byte[]streamToHash
System.IO.Streamhash
byte[]hashAlgorithmOid
OID