internal static void Validate(ServiceStartedPayload toValidate, IList validated) { if (validated.Contains(toValidate)) { return; } validated.Add(toValidate); if (toValidate.Domain == null) { throw new ArgumentException("Domain is required"); } if (toValidate.Service == null) { throw new ArgumentException("Service is required"); } }
public static void Validate(ServiceStartedPayload toValidate) { Validate(toValidate, new ArrayList()); }