Class: ReactionUserManager

ReactionUserManager

Manages API methods for users who reacted to a reaction and stores their cache.

Constructor

new ReactionUserManager()

Source:

Extends

Members

cache :Collection.<Snowflake, User>

The cache of this manager
Type:
Overrides:
Source:

cacheType :Collection

The type of Collection of the Manager
Type:
  • Collection
Overrides:
Source:

(readonly) client :Client

The client that instantiated this Manager
Type:
Overrides:
Source:

(private, readonly) holds :function

The data structure belonging to this manager
Type:
  • function
Overrides:
Source:

reaction :MessageReaction

The reaction that this manager belongs to
Type:
Source:

Methods

fetch(optionsopt) → {Promise.<Collection.<Snowflake, User>>}

Fetches all the users that gave this reaction. Resolves with a collection of users, mapped by their IDs.
Parameters:
Name Type Attributes Description
options Object <optional>
Options for fetching the users
Properties
Name Type Attributes Default Description
limit number <optional>
100 The maximum amount of users to fetch, defaults to 100
before Snowflake <optional>
Limit fetching users to those with an id lower than the supplied id
after Snowflake <optional>
Limit fetching users to those with an id greater than the supplied id
Source:
Returns:
Type
Promise.<Collection.<Snowflake, User>>

remove(useropt) → {Promise.<MessageReaction>}

Removes a user from this reaction.
Parameters:
Name Type Attributes Default Description
user UserResolvable <optional>
this.reaction.message.client.user The user to remove the reaction of
Source:
Returns:
Type
Promise.<MessageReaction>

resolve(idOrInstance) → {Object}

Resolves a data entry to a data Object.
Parameters:
Name Type Description
idOrInstance string | Object The id or instance of something in this Manager
Overrides:
Source:
Returns:
An instance from this Manager
Type
Object

resolveID(idOrInstance) → {Snowflake}

Resolves a data entry to a instance ID.
Parameters:
Name Type Description
idOrInstance string | Object The id or instance of something in this Manager
Overrides:
Source:
Returns:
Type
Snowflake