Inheritance: ConfigurationResult
Beispiel #1
0
        public static ConfigurationResult CompileResults(IEnumerable <ValidationResult> results, string messagePrefix)
        {
            var result = new BusConfigurationResult(results);

            if (!result.ContainsFailure)
            {
                return(result);
            }

            var message = messagePrefix + Environment.NewLine + string.Join(Environment.NewLine, result.Results.Select(x => x.ToString()).ToArray());

            throw new ConfigurationException(result, message);
        }
        public static ConfigurationResult CompileResults(IEnumerable <ValidationResult> results)
        {
            var result = new BusConfigurationResult(results);

            if (!result.ContainsFailure)
            {
                return(result);
            }

            string message = "The service bus was not properly configured:" + Environment.NewLine +
                             string.Join(Environment.NewLine, result.Results.Select(x => x.ToString()).ToArray());

            throw new ConfigurationException(result, message);
        }
        public static ConfigurationResult CompileResults(IEnumerable<ValidationResult> results)
        {
            var result = new BusConfigurationResult(results);

            if (result.ContainsFailure)
            {
                string message = "The service bus was not properly configured:" +
                    Environment.NewLine +
                    string.Join(Environment.NewLine, result.Results.Select(x => x.ToString()).ToArray());

                throw new ConfigurationException(result, message);
            }

            return result;
        }