示例#1
0
        public override int GetHashCode()
        {
            int hash = 17;

            hash = hash * 23 + Version.GetHashCode();
            hash = hash * 23 + ImageBase.GetHashCode();
            hash = hash * 23 + FilePath.GetHashCode();
            hash = hash * 23 + FileName.GetHashCode();
            hash = hash * 23 + FileSize.GetHashCode();
            hash = hash * 23 + IsManaged.GetHashCode();
            hash = hash * 23 + TimeStamp.GetHashCode();
            hash = hash * 23 + PdbInfo.GetHashCode();
            hash = hash * 23 + Tags.GetHashCode();
            return(hash);
        }
示例#2
0
        /// <summary>
        ///     Returns a hash code for this instance.
        /// </summary>
        /// <returns>A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table.</returns>
        /// <inheritdoc />
        public override int GetHashCode()
        {
            unchecked
            {
                var hashCode = FileName != null?FileName.GetHashCode() : 0;

                hashCode = (hashCode * 397) ^ (int)FileSize;
                hashCode = (hashCode * 397) ^ ImageBase.GetHashCode();
                hashCode = (hashCode * 397) ^ IsManaged.GetHashCode();
                hashCode = (hashCode * 397) ^ IsRuntime.GetHashCode();
                hashCode = (hashCode * 397) ^ (Pdb != null ? Pdb.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ (PeFile != null ? PeFile.GetHashCode() : 0);
                hashCode = (hashCode * 397) ^ (int)TimeStamp;
                hashCode = (hashCode * 397) ^ Version.GetHashCode();
                return(hashCode);
            }
        }
示例#3
0
 public override int GetHashCode()
 {
     return(Utilities.CombineHashCodes(Target.GetHashCode(), ImageBase.GetHashCode()));
 }