Xaye.Fred.Fred.Fred C# (CSharp) Méthode

Fred() public méthode

Creates a Fred object with the given developer key.
public Fred ( string key, HttpClient httpClient, bool cacheSeries = true ) : System
key string The FRED developer key.
httpClient HttpClient The HttpClient to use. This is helpful if you need add proxy settings.
cacheSeries bool Should this Fred object cache series as it downloads them.
Résultat System
        public Fred(string key, HttpClient httpClient, bool cacheSeries = true)
        {
            var trimmed = key.Trim();
            if (IsNullOrWhiteSpace(trimmed))
            {
                throw new ArgumentNullException(nameof(key), "The FRED key cannot be null or an empty string.");
            }

            _cache = cacheSeries;
            _key = trimmed;
            _downloader = httpClient;
        }

Same methods

Fred::Fred ( string key, WebClient webClient, bool cacheSeries = true ) : System
Fred::Fred ( string key, bool cacheSeries = true ) : System