Interface EntityRetriever

    • Method Detail

      • getChannelById

        Mono<Channel> getChannelById​(Snowflake channelId)
        Requests to retrieve the channel represented by the supplied ID.
        Parameters:
        channelId - The ID of the channel.
        Returns:
        A Mono where, upon successful completion, emits the Channel as represented by the supplied ID. If an error is received, it is emitted through the Mono.
      • getGuildById

        Mono<Guild> getGuildById​(Snowflake guildId)
        Requests to retrieve the guild represented by the supplied ID.
        Parameters:
        guildId - The ID of the guild.
        Returns:
        A Mono where, upon successful completion, emits the Guild as represented by the supplied ID. If an error is received, it is emitted through the Mono.
      • getGuildEmojiById

        Mono<GuildEmoji> getGuildEmojiById​(Snowflake guildId,
                                           Snowflake emojiId)
        Requests to retrieve the guild emoji represented by the supplied IDs.
        Parameters:
        guildId - The ID of the guild.
        emojiId - The ID of the emoji.
        Returns:
        A Mono where, upon successful completion, emits the GuildEmoji as represented by the supplied IDs. If an error is received, it is emitted through the Mono.
      • getMemberById

        Mono<Member> getMemberById​(Snowflake guildId,
                                   Snowflake userId)
        Requests to retrieve the member represented by the supplied IDs. Depending on the implementation, it is possible to lazily request member entities from the Gateway, or the REST API.
        Parameters:
        guildId - The ID of the guild.
        userId - The ID of the user.
        Returns:
        A Mono where, upon successful completion, emits the Member as represented by the supplied IDs. If an error is received, it is emitted through the Mono.
      • getMessageById

        Mono<Message> getMessageById​(Snowflake channelId,
                                     Snowflake messageId)
        Requests to retrieve the message represented by the supplied IDs.
        Parameters:
        channelId - The ID of the channel.
        messageId - The ID of the message.
        Returns:
        A Mono where, upon successful completion, emits the Message as represented by the supplied IDs. If an error is received, it is emitted through the Mono.
      • getRoleById

        Mono<Role> getRoleById​(Snowflake guildId,
                               Snowflake roleId)
        Requests to retrieve the role represented by the supplied IDs.
        Parameters:
        guildId - The ID of the guild.
        roleId - The ID of the role.
        Returns:
        A Mono where, upon successful completion, emits the Role as represented by the supplied IDs. If an error is received, it is emitted through the Mono.
      • getUserById

        Mono<User> getUserById​(Snowflake userId)
        Requests to retrieve the user represented by the supplied ID.
        Parameters:
        userId - The ID of the user.
        Returns:
        A Mono where, upon successful completion, emits the User as represented by the supplied ID. If an error is received, it is emitted through the Mono.
      • getGuilds

        Flux<Guild> getGuilds()
        Requests to retrieve the guilds the current client is in.
        Returns:
        A Flux that continually emits the guilds that the current client is in. If an error is received, it is emitted through the Flux.
      • getSelf

        Mono<User> getSelf()
        Requests to retrieve the bot user.
        Returns:
        A Mono where, upon successful completion, emits the bot user. If an error is received, it is emitted through the Mono.
      • getSelfMember

        Mono<Member> getSelfMember​(Snowflake guildId)
        Requests to retrieve the bot user represented as a member of the guild with the supplied ID.
        Parameters:
        guildId - The ID of the guild.
        Returns:
        A Mono where, upon successful completion, emits the bot member. If an error is received, it is emitted through the Mono.
      • getGuildMembers

        Flux<Member> getGuildMembers​(Snowflake guildId)
        Requests to retrieve the guild's members.
        Parameters:
        guildId - the ID of the guild.
        Returns:
        A Flux that continually emits the members of the guild. If an error is received, it is emitted through the Flux.
      • getGuildChannels

        Flux<GuildChannel> getGuildChannels​(Snowflake guildId)
        Requests to retrieve the guild's channels.

        The order of items emitted by the returned Flux is unspecified. Use OrderUtil.orderGuildChannels(Flux) to consistently order channels.

        Parameters:
        guildId - the ID of the guild.
        Returns:
        A Flux that continually emits the guild's channels. If an error is received, it is emitted through the Flux.
      • getGuildRoles

        Flux<Role> getGuildRoles​(Snowflake guildId)
        Requests to retrieve the guild's roles.

        The order of items emitted by the returned Flux is unspecified. Use OrderUtil.orderRoles(Flux) to consistently order roles.

        Returns:
        A Flux that continually emits the guild's roles. If an error is received, it is emitted through the Flux.
      • getGuildEmojis

        Flux<GuildEmoji> getGuildEmojis​(Snowflake guildId)
        Requests to retrieve the guild's emojis.
        Returns:
        A Flux that continually emits the guild's emojis. If an error is received, it is emitted through the Flux.