/// <summary> /// Determines if the current MimeType is equal to another MimeType. /// </summary> /// <param name="value">The other <see cref="MimeType"/> instance to compare to.</param> /// <param name="comparison">The kind of string comparison to use.</param> /// <returns>true if the current instance represents the same value as the specified instance; otherwise, false.</returns> public bool Equals(MimeType value, StringComparison comparison) { return MimeType.Equals(this, value, comparison); }
/// <summary> /// Determines if two <see cref="MimeType"/> instances are equal. /// </summary> /// <param name="a">The first <see cref="MimeType"/> instance to compare.</param> /// <param name="b">The second <see cref="MimeType"/> instance to compare.</param> /// <param name="comparison">The kind of string comparison to use.</param> /// <returns>true if both instances represent the same value; otherwise, false.</returns> public static bool Equals(MimeType a, MimeType b, StringComparison comparison) { return a.Type.Equals(b.Type, comparison) && a.Subtype.Equals(b.Subtype, comparison); }
/// <summary> /// Determines if the current MimeType is equal to another MimeType. /// </summary> /// <param name="value">The other <see cref="MimeType"/> instance to compare to.</param> /// <returns>true if the current instance represents the same value as the specified instance; otherwise, false.</returns> public bool Equals(MimeType value) { return MimeType.Equals(this, value, MimeType.DefaultComparison); }
/// <summary> /// Determines if two <see cref="MimeType"/> instances are equal. /// </summary> /// <param name="a">The first <see cref="MimeType"/> instance to compare.</param> /// <param name="b">The second <see cref="MimeType"/> instance to compare.</param> /// <returns>true if both instances represent the same value; otherwise, false.</returns> public static bool Equals(MimeType a, MimeType b) { return MimeType.Equals(a, b, MimeType.DefaultComparison); }