Exemplo n.º 1
0
 /// <summary>
 /// Checks is the Hashes are equal
 /// </summary>
 /// <param name="hash">Hash to compare with</param>
 /// <returns>True, if the Hash are equal</returns>
 /// <exception cref="ArgumentNullException"></exception>
 public virtual bool Verify(IHashed hash)
 {
     if (hash == null)
     {
         throw new ArgumentNullException(nameof(hash));
     }
     return(Utils.Secure.Compare(HashBytes, hash?.HashBytes));
 }
Exemplo n.º 2
0
 public KeyComparer(Table <T> table, IHashed <TKey, T> trigger)
 {
     this.table   = table;
     this.trigger = trigger;
 }