Class ReadActions
java.lang.Object
discord4j.common.store.action.read.ReadActions
Provides static factories to obtain
StoreAction
instances that enable reading data from a store.-
Method Summary
Modifier and TypeMethodDescriptionstatic CountTotalAction
Creates an action to count the number of channels present in a store.static CountInGuildAction
countChannelsInGuild
(long guildId) Creates an action to count the number of channels present in a store for the given guild ID.static CountTotalAction
Creates an action to count the number of emojis present in a store.static CountInGuildAction
countEmojisInGuild
(long guildId) Creates an action to count the number of emojis present in a store for the given guild ID.static CountInGuildAction
countExactMembersInGuild
(long guildId) Creates an action to count the exact number of members for the given guild ID.static CountTotalAction
Creates an action to count the number of guilds present in a store.static CountTotalAction
Creates an action to count the number of members present in a store.static CountInGuildAction
countMembersInGuild
(long guildId) Creates an action to count the number of members present in a store for the given guild ID.static CountTotalAction
Creates an action to count the number of messages present in a store.static CountMessagesInChannelAction
countMessagesInChannel
(long channelId) Creates an action to count the number of messages present in a store for the given channel ID.static CountTotalAction
Creates an action to count the number of presences present in a store.static CountInGuildAction
countPresencesInGuild
(long guildId) Creates an action to count the number of presences present in a store for the given guild ID.static CountTotalAction
Creates an action to count the number of roles present in a store.static CountInGuildAction
countRolesInGuild
(long guildId) Creates an action to count the number of roles present in a store for the given guild ID.static CountTotalAction
Creates an action to count the number of users present in a store.static CountTotalAction
Creates an action to count the number of voice states present in a store.countVoiceStatesInChannel
(long guildId, long channelId) Creates an action to count the number of voice states present in a store for the given guild ID and channel ID.static CountInGuildAction
countVoiceStatesInGuild
(long guildId) Creates an action to count the number of voice states present in a store for the given guild ID.static GetAutoModRuleByIdAction
getAutoModRuleById
(long guildId, long autoModRuleId) Creates an action to retrieve data for the automod rule corresponding to the given guild ID and automod rule ID.static GetAutoModRulesInGuildAction
getAutoModRulesInGuild
(long guildId) Creates an action to retrieve data for all automod rules present in a store for the given guild ID.static GetChannelByIdAction
getChannelById
(long channelId) Creates an action to retrieve data for the channel corresponding to the given channel ID.static GetChannelsAction
Creates an action to retrieve data for all channels present in a store.static GetChannelsInGuildAction
getChannelsInGuild
(long guildId) Creates an action to retrieve data for all channels present in a store for the given guild ID.static GetEmojiByIdAction
getEmojiById
(long guildId, long emojiId) Creates an action to retrieve data for the emoji corresponding to the given guild ID and emoji ID.static GetEmojisAction
Creates an action to retrieve data for all emojis present in a store.static GetEmojisInGuildAction
getEmojisInGuild
(long guildId) Creates an action to retrieve data for all emojis present in a store for the given guild ID.static GetExactMembersInGuildAction
getExactMembersInGuild
(long guildId) Creates an action to retrieve data for all members for the given guild ID.static GetGuildByIdAction
getGuildById
(long guildId) Creates an action to retrieve data for the guild corresponding to the given guild ID.static GetGuildsAction
Creates an action to retrieve data for all guilds present in a store.static GetMemberByIdAction
getMemberById
(long guildId, long userId) Creates an action to retrieve data for the member corresponding to the given guild ID and user ID.static GetMembersAction
Creates an action to retrieve data for all members present in a store.static GetMembersInGuildAction
getMembersInGuild
(long guildId) Creates an action to retrieve data for all members present in a store for the given guild ID.static GetMembersInThreadAction
getMembersInThread
(long threadId) Creates an action to retrieve data for all thread members present in a store for the given thread ID.static GetMessageByIdAction
getMessageById
(long channelId, long messageId) Creates an action to retrieve data for the message corresponding to the given channel ID and message ID.static GetMessagesAction
Creates an action to retrieve data for all messages present in a store.static GetMessagesInChannelAction
getMessagesInChannel
(long channelId) Creates an action to retrieve data for all messages present in a store for the given channel ID.static GetPresenceByIdAction
getPresenceById
(long guildId, long userId) Creates an action to retrieve data for the presence corresponding to the given guild ID and user ID.static GetPresencesAction
Creates an action to retrieve data for all presences present in a store.static GetPresencesInGuildAction
getPresencesInGuild
(long guildId) Creates an action to retrieve data for all presences present in a store for the given guild ID.static GetRoleByIdAction
getRoleById
(long guildId, long roleId) Creates an action to retrieve data for the role corresponding to the given guild ID and role ID.static GetRolesAction
getRoles()
Creates an action to retrieve data for all roles present in a store.static GetRolesInGuildAction
getRolesInGuild
(long guildId) Creates an action to retrieve data for all roles present in a store for the given guild ID.getStageInstanceByChannelId
(long channelId) Creates an action to retrieve data for the stage instance corresponding to the given channel ID.static GetStickerByIdAction
getStickerById
(long guildId, long stickerId) Creates an action to retrieve data for the sticker corresponding to the given guild ID and sticker ID.static GetStickersInGuildAction
getStickersInGuild
(long guildId) Creates an action to retrieve data for all stickers present in a store for the given guild ID.static GetThreadMemberByIdAction
getThreadMemberById
(long threadId, long userId) Creates an action to retrieve data for the thread member corresponding to the given thread ID and user ID.static GetUserByIdAction
getUserById
(long userId) Creates an action to retrieve data for the user corresponding to the given user ID.static GetUsersAction
getUsers()
Creates an action to retrieve data for all users present in a store.static GetVoiceStateByIdAction
getVoiceStateById
(long guildId, long userId) Creates an action to retrieve data for the voice state corresponding to the given guild ID and user ID.static GetVoiceStatesAction
Creates an action to retrieve data for all voice states present in a store.getVoiceStatesInChannel
(long guildId, long channelId) Creates an action to retrieve data for all voice states present in a store for the given guild ID and channel ID.static GetVoiceStatesInGuildAction
getVoiceStatesInGuild
(long guildId) Creates an action to retrieve data for all voice states present in a store for the given guild ID.
-
Method Details
-
countChannels
Creates an action to count the number of channels present in a store.- Returns:
- a new
CountTotalAction
-
countChannelsInGuild
Creates an action to count the number of channels present in a store for the given guild ID.- Parameters:
guildId
- the guild ID- Returns:
- a new
CountInGuildAction
-
countEmojis
Creates an action to count the number of emojis present in a store.- Returns:
- a new
CountTotalAction
-
countEmojisInGuild
Creates an action to count the number of emojis present in a store for the given guild ID.- Parameters:
guildId
- the guild ID- Returns:
- a new
CountInGuildAction
-
countGuilds
Creates an action to count the number of guilds present in a store.- Returns:
- a new
CountTotalAction
-
countMembers
Creates an action to count the number of members present in a store.- Returns:
- a new
CountTotalAction
-
countMembersInGuild
Creates an action to count the number of members present in a store for the given guild ID.- Parameters:
guildId
- the guild ID- Returns:
- a new
CountInGuildAction
-
countExactMembersInGuild
Creates an action to count the exact number of members for the given guild ID. If some members are not present in the store and thus is not able to return an accurate count, executing this action will error withExactResultNotAvailableException
.- Parameters:
guildId
- the guild ID- Returns:
- a new
CountInGuildAction
-
countMessages
Creates an action to count the number of messages present in a store.- Returns:
- a new
CountTotalAction
-
countMessagesInChannel
Creates an action to count the number of messages present in a store for the given channel ID.- Parameters:
channelId
- the channel ID- Returns:
- a new
CountMessagesInChannelAction
-
countPresences
Creates an action to count the number of presences present in a store.- Returns:
- a new
CountTotalAction
-
countPresencesInGuild
Creates an action to count the number of presences present in a store for the given guild ID.- Parameters:
guildId
- the guild ID- Returns:
- a new
CountInGuildAction
-
countRoles
Creates an action to count the number of roles present in a store.- Returns:
- a new
CountTotalAction
-
countRolesInGuild
Creates an action to count the number of roles present in a store for the given guild ID.- Parameters:
guildId
- the guild ID- Returns:
- a new
CountInGuildAction
-
countUsers
Creates an action to count the number of users present in a store.- Returns:
- a new
CountTotalAction
-
countVoiceStates
Creates an action to count the number of voice states present in a store.- Returns:
- a new
CountTotalAction
-
countVoiceStatesInGuild
Creates an action to count the number of voice states present in a store for the given guild ID.- Parameters:
guildId
- the guild ID- Returns:
- a new
CountInGuildAction
-
countVoiceStatesInChannel
public static CountVoiceStatesInChannelAction countVoiceStatesInChannel(long guildId, long channelId) Creates an action to count the number of voice states present in a store for the given guild ID and channel ID.- Parameters:
guildId
- the guild IDchannelId
- the channel ID- Returns:
- a new
CountMessagesInChannelAction
-
getChannels
Creates an action to retrieve data for all channels present in a store.- Returns:
- a new
GetChannelsAction
-
getChannelsInGuild
Creates an action to retrieve data for all channels present in a store for the given guild ID.- Parameters:
guildId
- the guild ID- Returns:
- a new
GetChannelsInGuildAction
-
getChannelById
Creates an action to retrieve data for the channel corresponding to the given channel ID.- Parameters:
channelId
- the channel ID- Returns:
- a new
GetChannelByIdAction
-
getStickersInGuild
Creates an action to retrieve data for all stickers present in a store for the given guild ID.- Parameters:
guildId
- the guild ID- Returns:
- a new
GetStickersInGuildAction
-
getStickerById
Creates an action to retrieve data for the sticker corresponding to the given guild ID and sticker ID.- Parameters:
guildId
- the guild IDstickerId
- the sticker ID- Returns:
- a new
GetStickerByIdAction
-
getAutoModRulesInGuild
Creates an action to retrieve data for all automod rules present in a store for the given guild ID.- Parameters:
guildId
- the guild ID- Returns:
- a new
GetAutoModRulesInGuildAction
-
getAutoModRuleById
Creates an action to retrieve data for the automod rule corresponding to the given guild ID and automod rule ID.- Parameters:
guildId
- the guild IDautoModRuleId
- the automod rule ID- Returns:
- a new
GetAutoModRuleByIdAction
-
getEmojis
Creates an action to retrieve data for all emojis present in a store.- Returns:
- a new
GetEmojisAction
-
getEmojisInGuild
Creates an action to retrieve data for all emojis present in a store for the given guild ID.- Parameters:
guildId
- the guild ID- Returns:
- a new
GetEmojisInGuildAction
-
getEmojiById
Creates an action to retrieve data for the emoji corresponding to the given guild ID and emoji ID.- Parameters:
guildId
- the guild IDemojiId
- the emoji ID- Returns:
- a new
GetEmojiByIdAction
-
getGuilds
Creates an action to retrieve data for all guilds present in a store.- Returns:
- a new
GetGuildsAction
-
getGuildById
Creates an action to retrieve data for the guild corresponding to the given guild ID.- Parameters:
guildId
- the guild ID- Returns:
- a new
GetGuildByIdAction
-
getMembers
Creates an action to retrieve data for all members present in a store.- Returns:
- a new
GetMembersAction
-
getMembersInGuild
Creates an action to retrieve data for all members present in a store for the given guild ID.- Parameters:
guildId
- the guild ID- Returns:
- a new
GetMembersInGuildAction
-
getExactMembersInGuild
Creates an action to retrieve data for all members for the given guild ID. If some members are not present in the store and thus is not able to return the full member list of the guild, executing this action will error withExactResultNotAvailableException
.- Parameters:
guildId
- the guild ID- Returns:
- a new
GetExactMembersInGuildAction
-
getMemberById
Creates an action to retrieve data for the member corresponding to the given guild ID and user ID.- Parameters:
guildId
- the guild IDuserId
- the user ID- Returns:
- a new
GetMemberByIdAction
-
getMessages
Creates an action to retrieve data for all messages present in a store.- Returns:
- a new
GetMessagesAction
-
getMessagesInChannel
Creates an action to retrieve data for all messages present in a store for the given channel ID.- Parameters:
channelId
- the channel ID- Returns:
- a new
GetMessagesInChannelAction
-
getMessageById
Creates an action to retrieve data for the message corresponding to the given channel ID and message ID.- Parameters:
channelId
- the channel IDmessageId
- the message ID- Returns:
- a new
GetMessageByIdAction
-
getPresences
Creates an action to retrieve data for all presences present in a store.- Returns:
- a new
GetPresencesAction
-
getPresencesInGuild
Creates an action to retrieve data for all presences present in a store for the given guild ID.- Parameters:
guildId
- the guild ID- Returns:
- a new
GetPresencesInGuildAction
-
getPresenceById
Creates an action to retrieve data for the presence corresponding to the given guild ID and user ID.- Parameters:
guildId
- the guild IDuserId
- the user ID- Returns:
- a new
GetPresenceByIdAction
-
getRoles
Creates an action to retrieve data for all roles present in a store.- Returns:
- a new
GetRolesAction
-
getRolesInGuild
Creates an action to retrieve data for all roles present in a store for the given guild ID.- Parameters:
guildId
- the guild ID- Returns:
- a new
GetRolesInGuildAction
-
getRoleById
Creates an action to retrieve data for the role corresponding to the given guild ID and role ID.- Parameters:
guildId
- the guild IDroleId
- the role ID- Returns:
- a new
GetRoleByIdAction
-
getUsers
Creates an action to retrieve data for all users present in a store.- Returns:
- a new
GetUsersAction
-
getUserById
Creates an action to retrieve data for the user corresponding to the given user ID.- Parameters:
userId
- the user ID- Returns:
- a new
GetUserByIdAction
-
getVoiceStates
Creates an action to retrieve data for all voice states present in a store.- Returns:
- a new
GetVoiceStatesAction
-
getVoiceStatesInChannel
Creates an action to retrieve data for all voice states present in a store for the given guild ID and channel ID.- Parameters:
guildId
- the guild IDchannelId
- the channel ID- Returns:
- a new
GetVoiceStatesInChannelAction
-
getVoiceStatesInGuild
Creates an action to retrieve data for all voice states present in a store for the given guild ID.- Parameters:
guildId
- the guild ID- Returns:
- a new
GetVoiceStatesInGuildAction
-
getVoiceStateById
Creates an action to retrieve data for the voice state corresponding to the given guild ID and user ID.- Parameters:
guildId
- the guild IDuserId
- the user ID- Returns:
- a new
GetVoiceStateByIdAction
-
getStageInstanceByChannelId
Creates an action to retrieve data for the stage instance corresponding to the given channel ID.- Parameters:
channelId
- the channel ID- Returns:
- a new
GetStageInstanceByChannelIdAction
-
getThreadMemberById
Creates an action to retrieve data for the thread member corresponding to the given thread ID and user ID.- Parameters:
threadId
- the thread IDuserId
- the user ID- Returns:
- a new
GetThreadMemberByIdAction
-
getMembersInThread
Creates an action to retrieve data for all thread members present in a store for the given thread ID.- Parameters:
threadId
- the thread ID- Returns:
- a new
GetMembersInThreadAction
-