Ejemplo n.º 1
0
 /// <exception cref="System.Exception"></exception>
 public BulkDownloader(BulkDownloaderOptions options)
 {
     options.Validate();
     _bulkGetUri     = new Uri(AppendRelativeURLString(options.DatabaseUri, "/_bulk_get?revs=true&attachments=true"));
     _db             = options.Database;
     _httpClient     = options.ClientFactory.GetHttpClient(options.CookieStore, options.RetryStrategy);
     _requestHeaders = options.RequestHeaders;
     _tokenSource    = options.TokenSource ?? new CancellationTokenSource();
     _body           = CreatePostBody(options.Revisions, _db);
 }
Ejemplo n.º 2
0
        /// <exception cref="System.Exception"></exception>
        public BulkDownloader(BulkDownloaderOptions options)
        {
            options.Validate();
            _bulkGetUri = new Uri(AppendRelativeURLString(options.DatabaseUri, "/_bulk_get?revs=true&attachments=true"));
            _db         = options.Database;

            _requestHeaders = options.RequestHeaders;
            _tokenSource    = options.TokenSource ?? new CancellationTokenSource();
            _body           = CreatePostBody(options.Revisions, _db);
            _session        = options.Session;
        }
 /// <exception cref="System.Exception"></exception>
 public BulkDownloader(BulkDownloaderOptions options)
 {
     options.Validate();
     _bulkGetUri = new Uri(AppendRelativeURLString(options.DatabaseUri, "/_bulk_get?revs=true&attachments=true"));
     _db = options.Database;
     _httpClient = options.ClientFactory.GetHttpClient(options.CookieStore, options.RetryStrategy);
     _requestHeaders = options.RequestHeaders;
     _tokenSource = options.TokenSource ?? new CancellationTokenSource();
     _body = CreatePostBody(options.Revisions, _db);
 }