Exemplo n.º 1
0
        /// <summary>
        /// Validates a set of urls
        /// </summary>
        /// <param name="configuration">Configuration options to set for the data quality engine. Omit if you want to use the default behavior. The default behavior assumes that the protocol is http</param>
        /// <param name="urls"></param>
        public UrlValidation(UrlValidationRequestConfiguration configuration, IEnumerable <string> urls)
        {
            var records = urls.Select(url => new UrlValidationRequestRecord
            {
                Url = url
            })
                          .ToList();

            Content = new UrlValidationRequest(configuration, records);
        }
Exemplo n.º 2
0
 /// <summary>
 ///     Gets response from the service with url validation results.
 /// </summary>
 /// <param name="request">The URL validaton request</param>
 /// <returns>The URL validation response with validation results for each URL.</returns>
 public Task <UrlValidationResponse> GetResponseAsync(UrlValidationRequest request)
 {
     return(Task.Factory.StartNew(() => GetResponse(request)));
 }
Exemplo n.º 3
0
 /// <summary>
 ///     Gets response from the service with url validation results.
 /// </summary>
 /// <param name="request">The URL validaton request</param>
 /// <returns>The URL validation response with validation results for each URL.</returns>
 public UrlValidationResponse GetResponse(UrlValidationRequest request)
 {
     return(GetRestResponse <UrlValidationRequest, UrlValidationResponse>(request, "/valid"));
 }
Exemplo n.º 4
0
 /// <summary>
 /// Validates a set of urls
 /// </summary>
 /// <param name="configuration">Configuration options to set for the data quality engine. Omit if you want to use the default behavior. The default behavior assumes that the protocol is http</param>
 /// <param name="urls"></param>
 public UrlValidation(UrlValidationRequestConfiguration configuration,
                      List <UrlValidationRequestRecord> records)
 {
     Content = new UrlValidationRequest(configuration, records);
 }
Exemplo n.º 5
0
 /// <summary>
 /// Validates a set of urls
 /// </summary>
 /// <param name="content"></param>
 public UrlValidation(UrlValidationRequest content)
 {
     Content = content;
 }