public string ComputeHash(SampleData inputData) { var lhash = (ulong) inputData.FileLength; for (var i = 0; i < inputData.DataBytes.Length; i += 8) unchecked { lhash += BitConverter.ToUInt64(inputData.DataBytes, i); } return lhash.ToString("x16"); }
public bool Equals(SampleData other) { return other.FileLength == FileLength && other.DataBytes.SequenceEqual(DataBytes); }