Class HashDigestExtensions
Augments types to have some shortcut methods dealing with HashDigest<T> values.
Inheritance
System.Object
HashDigestExtensions
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Libplanet.Common
Assembly: Libplanet.Common.dll
Syntax
public static class HashDigestExtensions
Methods
| Improve this Doc View SourceToHashDigest<T>(String)
Converts a given hexadecimal representation of a digest into a HashDigest<T> object.
This is a shortcut of FromString(String) method.
This is an inverse function of ToString() method.
Declaration
public static HashDigest<T> ToHashDigest<T>(this string hexDigest)
where T : HashAlgorithm
Parameters
Type | Name | Description |
---|---|---|
System.String | hexDigest | A hexadecimal representation of a HashDigest<T>. |
Returns
Type | Description |
---|---|
HashDigest<T> | A corresponding HashDigest<T> value. |
Type Parameters
Name | Description |
---|---|
T | A System.Security.Cryptography.HashAlgorithm which corresponds to a digest. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | Thrown when the given
|
System.ArgumentOutOfRangeException | Thrown when the given
|