mirror of
https://github.com/JKorf/CryptoExchange.Net
synced 2025-06-07 07:56:12 +00:00
Added setting logwriter and ratelimites
This commit is contained in:
parent
2bf860947a
commit
825a3d1f90
@ -23,7 +23,7 @@ namespace CryptoExchange.Net
|
||||
protected ApiProxy apiProxy;
|
||||
|
||||
private AuthenticationProvider authProvider;
|
||||
private readonly List<IRateLimiter> rateLimiters = new List<IRateLimiter>();
|
||||
private List<IRateLimiter> rateLimiters;
|
||||
|
||||
protected ExchangeClient(ExchangeOptions exchangeOptions, AuthenticationProvider authentictationProvider)
|
||||
{
|
||||
@ -38,9 +38,13 @@ namespace CryptoExchange.Net
|
||||
/// <param name="exchangeOptions">Options</param>
|
||||
protected void Configure(ExchangeOptions exchangeOptions)
|
||||
{
|
||||
if (exchangeOptions.LogWriter != null)
|
||||
log.TextWriter = exchangeOptions.LogWriter;
|
||||
|
||||
log.Level = exchangeOptions.LogVerbosity;
|
||||
apiProxy = exchangeOptions.Proxy;
|
||||
|
||||
rateLimiters = new List<IRateLimiter>();
|
||||
foreach (var rateLimiter in exchangeOptions.RateLimiters)
|
||||
rateLimiters.Add(rateLimiter);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user