public void OnHttpRequest(ApiReader reader, HttpResponseMessage responseMessage) { if (isReadyToReset()) { resetLimiter(); } currentRateCounter++; }
public void NotifyAll(ApiReader reader, IApiResponse responseMessage) { rateLimiters.ForEach(i => i.OnHttpRequest(reader, responseMessage)); }
/// <summary> /// Declare this Configuration as the global default configuration, it will be used when no configuration is provided to the api reader. /// </summary> public ApiConfiguration DeclareAsDefault() { ApiReader.SetDefaultConfiguration(this); return(this); }