public InspectionResult(InspectionDecision decision, IPEndPoint tcpEndPoint = null, IPEndPoint secureTcpEndPoint = null) { if (decision == InspectionDecision.Reconnect) Ensure.NotNull(tcpEndPoint, "tcpEndPoint"); else { if (tcpEndPoint != null) throw new ArgumentException(string.Format("tcpEndPoint is not null for decision {0}.", decision)); } Decision = decision; TcpEndPoint = tcpEndPoint; SecureTcpEndPoint = secureTcpEndPoint; }
public InspectionResult(InspectionDecision decision, IPEndPoint tcpEndPoint = null, IPEndPoint secureTcpEndPoint = null) { if (decision == InspectionDecision.Reconnect) { Ensure.NotNull(tcpEndPoint, "tcpEndPoint"); } else { if (tcpEndPoint != null) { throw new ArgumentException(string.Format("tcpEndPoint is not null for decision {0}.", decision)); } } Decision = decision; TcpEndPoint = tcpEndPoint; SecureTcpEndPoint = secureTcpEndPoint; }
public InspectionResult(InspectionDecision decision, string description, EndPoint tcpEndPoint = null, EndPoint secureTcpEndPoint = null) { if (decision == InspectionDecision.Reconnect) { if (tcpEndPoint == null && secureTcpEndPoint == null) { throw new ArgumentNullException("Both TCP endpoints are null"); } } else { if (tcpEndPoint != null || secureTcpEndPoint != null) { throw new ArgumentException(string.Format("tcpEndPoint or secureTcpEndPoint is not null for decision {0}.", decision)); } } Decision = decision; Description = description; TcpEndPoint = tcpEndPoint; SecureTcpEndPoint = secureTcpEndPoint; }
public InspectionResult(InspectionDecision decision, Exception error = null) { Decision = decision; Error = error; }
public InspectionResult(InspectionDecision decision, string description) { Decision = decision; Description = description; }
public InspectionResult(InspectionDecision decision, Exception error = null, object data = null) { Decision = decision; Error = error; Data = data; }
public InspectionResult(InspectionDecision decision, Exception error = null, object data = null) { Decision = decision; Error = error; Data = data; }
public InspectionResult(InspectionDecision decision, Exception error = null) { Decision = decision; Error = error; }