public int GetHashCode()

in DTDLValidator/DTDLValidator/Interactive/CompareCommand.cs [172:185]


        public int GetHashCode(DTPropertyInfo pi)
        {
            //Check whether the object is null
            if (Object.ReferenceEquals(pi, null)) return 0;

            //Get hash code for the Name field if it is not null.
            int hashPIName = pi.Name == null ? 0 : pi.Name.GetHashCode();

            //Get hash code for the Code field.
            int hashPISchema = pi.Schema.GetHashCode();

            //Calculate the hash code for the product.
            return hashPIName ^ hashPISchema;
        }