forked from stevencohn/OneMore
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Optimize the save performance of page elements
- Loading branch information
1 parent
0a0d604
commit 01c4a4b
Showing
4 changed files
with
81 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
//************************************************************************************************ | ||
// Copyright © 2032 Steven M Cohn. All rights reserved. | ||
//************************************************************************************************ | ||
|
||
namespace River.OneMoreAddIn | ||
{ | ||
using System.Numerics; | ||
using System.Security.Cryptography; | ||
using System.Text; | ||
|
||
|
||
internal static class HashAlgorithmExtensions | ||
{ | ||
public static string GetHashString(this HashAlgorithm algorithm, string s) | ||
{ | ||
var data = Encoding.UTF8.GetBytes(s); | ||
var hash = algorithm.ComputeHash(data); | ||
return new BigInteger(hash).ToString(); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters