예제 #1
0
파일: Result.cs 프로젝트: zainuvk/WWCP_OCPP
        /// <summary>
        /// Compares two results for equality.
        /// </summary>
        /// <param name="Result1">A result.</param>
        /// <param name="Result2">Another result.</param>
        /// <returns>True if both match; False otherwise.</returns>
        public static Boolean operator ==(Result Result1, Result Result2)
        {
            // If both are null, or both are same instance, return true.
            if (ReferenceEquals(Result1, Result2))
            {
                return(true);
            }

            // If one is null, but not both, return false.
            if (((Object)Result1 == null) || ((Object)Result2 == null))
            {
                return(false);
            }

            return(Result1.Equals(Result2));
        }