/// <summary> /// Compares two instances of this object. /// </summary> /// <param name="OperatorEVSEStatus1">An operator EVSE status.</param> /// <param name="OperatorEVSEStatus2">Another operator EVSE status.</param> /// <returns>true|false</returns> public static Boolean operator >(OperatorEVSEStatus OperatorEVSEStatus1, OperatorEVSEStatus OperatorEVSEStatus2) { if ((Object)OperatorEVSEStatus1 == null) { throw new ArgumentNullException(nameof(OperatorEVSEStatus1), "The given OperatorEVSEStatus1 must not be null!"); } return(OperatorEVSEStatus1.CompareTo(OperatorEVSEStatus2) > 0); }
/// <summary> /// Compares two results for equality. /// </summary> /// <param name="OperatorEVSEStatus1">An operator EVSE status.</param> /// <param name="OperatorEVSEStatus2">Another operator EVSE status.</param> /// <returns>True if both match; False otherwise.</returns> public static Boolean operator ==(OperatorEVSEStatus OperatorEVSEStatus1, OperatorEVSEStatus OperatorEVSEStatus2) { // If both are null, or both are same instance, return true. if (ReferenceEquals(OperatorEVSEStatus1, OperatorEVSEStatus2)) { return(true); } // If one is null, but not both, return false. if (((Object)OperatorEVSEStatus1 == null) || ((Object)OperatorEVSEStatus2 == null)) { return(false); } return(OperatorEVSEStatus1.Equals(OperatorEVSEStatus2)); }