Ejemplo n.º 1
0
        public override int GetHashCode()
        {
            var hash = 13;

            hash = (hash * 7) + FileOffset.GetHashCode();
            hash = (hash * 7) + FileSize.GetHashCode();
            hash = (hash * 7) + RelativeVirtualAddress.GetHashCode();
            hash = (hash * 7) + VirtualAddress.GetHashCode();
            hash = (hash * 7) + VirtualSize.GetHashCode();

            return(hash);
        }
Ejemplo n.º 2
0
 public override int GetHashCode()
 {
     unchecked
     {
         int result = (Cookie != null ? Cookie.GetHashCode() : 0);
         result = (result * 397) ^ Features.GetHashCode();
         result = (result * 397) ^ (FileFormatVersion != null ? FileFormatVersion.GetHashCode() : 0);
         result = (result * 397) ^ HeaderOffset.GetHashCode();
         result = (result * 397) ^ TimeStamp.GetHashCode();
         result = (result * 397) ^ (CreatorApplication != null ? CreatorApplication.GetHashCode() : 0);
         result = (result * 397) ^ (CreatorVersion != null ? CreatorVersion.GetHashCode() : 0);
         result = (result * 397) ^ CreatorHostOsType.GetHashCode();
         result = (result * 397) ^ PhsyicalSize.GetHashCode();
         result = (result * 397) ^ VirtualSize.GetHashCode();
         result = (result * 397) ^ (DiskGeometry != null ? DiskGeometry.GetHashCode() : 0);
         result = (result * 397) ^ DiskType.GetHashCode();
         result = (result * 397) ^ CheckSum.GetHashCode();
         result = (result * 397) ^ UniqueId.GetHashCode();
         result = (result * 397) ^ SavedState.GetHashCode();
         result = (result * 397) ^ (Reserved != null ? Reserved.GetHashCode() : 0);
         result = (result * 397) ^ (RawData != null ? RawData.GetHashCode() : 0);
         return(result);
     }
 }