Method Calculate
Calculate(object)
Creates the hash for an object.
Declaration
public static RawHash Calculate(object obj)
Parameters
| Type | Name | Description |
|---|---|---|
| object | obj | The object. |
Returns
| Type | Description |
|---|---|
| RawHash | Returns the hash of the object. |
Calculate(params object[])
Creates the hash for a set of objects.
Declaration
public static RawHash Calculate(params object[] objects)
Parameters
| Type | Name | Description |
|---|---|---|
| object[] | objects | The objects. |
Returns
| Type | Description |
|---|---|
| RawHash | Returns the hash of the set of objects. |
Calculate(Hash128, Hash128)
Creates the hash for a pair of Hash128 objects. Optimized specialization of the generic Calculate() methods that has been shown to be ~3x faster The generic function uses reflection to obtain the four 32bit fields in the Hash128 which is slow, this function uses more direct byte access
Declaration
public static RawHash Calculate(Hash128 hash1, Hash128 hash2)
Parameters
| Type | Name | Description |
|---|---|---|
| Hash128 | hash1 | The first hash to combine |
| Hash128 | hash2 | The second hash to combine |
Returns
| Type | Description |
|---|---|
| RawHash | Returns the combined hash of the two hashes. |
Calculate<T>(object)
Creates the hash for an object.
Declaration
public static RawHash Calculate<T>(object obj) where T : HashAlgorithm
Parameters
| Type | Name | Description |
|---|---|---|
| object | obj | The object. |
Returns
| Type | Description |
|---|---|
| RawHash | Returns the hash of the object. |
Type Parameters
| Name | Description |
|---|---|
| T | The hash algorithm type. |
Calculate<T>(params object[])
Creates the hash for a set of objects.
Declaration
public static RawHash Calculate<T>(params object[] objects) where T : HashAlgorithm
Parameters
| Type | Name | Description |
|---|---|---|
| object[] | objects | The objects. |
Returns
| Type | Description |
|---|---|
| RawHash | Returns the hash of the set of objects. |
Type Parameters
| Name | Description |
|---|---|
| T | The hash algorithm type. |