Table of Contents

Class ThrottleQuota

Namespace
Cuemon.AspNetCore.Http.Throttling
Assembly
Cuemon.AspNetCore.dll

Specifies the allowed quota and window duration of HTTP requests.

public class ThrottleQuota
Inheritance
Object
ThrottleQuota

Constructors

ThrottleQuota(Int32, Double, TimeUnit)

Initializes a new instance of the ThrottleQuota class.

public ThrottleQuota(int rateLimit, double window, TimeUnit windowUnit)

Parameters

rateLimit Int32

The allowed rate from within a given window.

window Double

The duration of the window.

windowUnit TimeUnit

One of the enumeration values that specifies the time unit of window.

ThrottleQuota(Int32, TimeSpan)

Initializes a new instance of the ThrottleQuota class.

public ThrottleQuota(int rateLimit, TimeSpan window)

Parameters

rateLimit Int32

The allowed rate from within a given window.

window TimeSpan

The duration of the window.

Properties

RateLimit

Gets the allowed rate before throttling.

public int RateLimit { get; }

Property Value

Int32

The allowed rate before throttling.

Window

Gets the allowed window duration before throttling.

public TimeSpan Window { get; }

Property Value

TimeSpan

The allowed window duration before throttling.