InMemoryBucketAccessor

Default in-memory BucketAccessor implementation using RateLimitScope.

Note: The rate limit scopes using guilds or channels are limited to guild-only events, a user rate limit is applied if the limitation is violated.

Parameters

scope

Scope of the rate limit, see RateLimitScope values.

configurationSupplier

A supplier of BucketConfiguration, describing the rate limits

Constructors

Link copied to clipboard
constructor(scope: RateLimitScope, configurationSupplier: BucketConfigurationSupplier)

Functions

Link copied to clipboard
open suspend override fun getBucket(context: BContext, event: GenericCommandInteractionEvent, commandInfo: ApplicationCommandInfo): Bucket
open suspend override fun getBucket(context: BContext, event: GenericComponentInteractionCreateEvent, rateLimitReference: ComponentRateLimitReference): Bucket
open suspend override fun getBucket(context: BContext, event: MessageReceivedEvent, commandInfo: TextCommandInfo): Bucket