/// <summary> /// Compares two instances of this object. /// </summary> /// <param name="SessionEventNature1">A meter type.</param> /// <param name="SessionEventNature2">Another meter type.</param> /// <returns>true|false</returns> public static Boolean operator >(SessionEventNatures SessionEventNature1, SessionEventNatures SessionEventNature2) { if ((Object)SessionEventNature1 == null) { throw new ArgumentNullException(nameof(SessionEventNature1), "The given SessionEventNature1 must not be null!"); } return(SessionEventNature1.CompareTo(SessionEventNature2) > 0); }
/// <summary> /// Compares two instances of this object. /// </summary> /// <param name="SessionEventNature1">A meter type.</param> /// <param name="SessionEventNature2">Another meter type.</param> /// <returns>true|false</returns> public static Boolean operator ==(SessionEventNatures SessionEventNature1, SessionEventNatures SessionEventNature2) { // If both are null, or both are same instance, return true. if (ReferenceEquals(SessionEventNature1, SessionEventNature2)) { return(true); } // If one is null, but not both, return false. if (((Object)SessionEventNature1 == null) || ((Object)SessionEventNature2 == null)) { return(false); } return(SessionEventNature1.Equals(SessionEventNature2)); }