Package net.dv8tion.jda.api.entities
Interface ThreadChannel
- All Superinterfaces:
Channel
,Comparable<GuildChannel>
,Formattable
,GuildChannel
,GuildMessageChannel
,IMemberContainer
,IMentionable
,ISnowflake
,MessageChannel
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptiondefault RestAction<Void>
addThreadMember
(Member member) default RestAction<Void>
addThreadMember
(User user) addThreadMemberById
(long id) default RestAction<Void>
default void
Returns theChannelManager
for this GuildChannel.int
int
default Member
getOwner()
default String
long
default ThreadMember
default GuildMessageChannel
default ThreadMember
int
default ThreadMember
getThreadMember
(Member member) default ThreadMember
getThreadMember
(User user) getThreadMemberById
(long id) default ThreadMember
boolean
boolean
default boolean
isJoined()
boolean
isLocked()
default boolean
isOwner()
default boolean
isPublic()
join()
leave()
default RestAction<Void>
removeThreadMember
(Member member) default RestAction<Void>
removeThreadMember
(User user) removeThreadMemberById
(long id) default RestAction<Void>
default RestAction<ThreadMember>
retrieveThreadMember
(Member member) Load the thread-member for the specified user.default RestAction<ThreadMember>
retrieveThreadMember
(User user) Load the thread-member for the specified user.retrieveThreadMemberById
(long id) Load the thread-member for the user with the specified id.default RestAction<ThreadMember>
Load the thread-member for the user with the specified id.Methods inherited from interface net.dv8tion.jda.api.entities.Channel
getAsMention, getJDA, getName, getType
Methods inherited from interface java.lang.Comparable
compareTo
Methods inherited from interface net.dv8tion.jda.api.entities.GuildChannel
delete, getGuild, getPermissionContainer
Methods inherited from interface net.dv8tion.jda.api.entities.GuildMessageChannel
canTalk, canTalk, clearReactionsById, clearReactionsById, clearReactionsById, clearReactionsById, clearReactionsById, clearReactionsById, deleteMessages, deleteMessagesByIds, removeReactionById, removeReactionById, removeReactionById, removeReactionById
Methods inherited from interface net.dv8tion.jda.api.entities.IMemberContainer
getMembers
Methods inherited from interface net.dv8tion.jda.api.entities.ISnowflake
getId, getIdLong, getTimeCreated
Methods inherited from interface net.dv8tion.jda.api.entities.MessageChannel
addReactionById, addReactionById, addReactionById, addReactionById, deleteMessageById, deleteMessageById, editMessageById, editMessageById, editMessageById, editMessageById, editMessageComponentsById, editMessageComponentsById, editMessageComponentsById, editMessageComponentsById, editMessageEmbedsById, editMessageEmbedsById, editMessageEmbedsById, editMessageEmbedsById, editMessageFormatById, editMessageFormatById, getHistory, getHistoryAfter, getHistoryAfter, getHistoryAfter, getHistoryAround, getHistoryAround, getHistoryAround, getHistoryBefore, getHistoryBefore, getHistoryBefore, getHistoryFromBeginning, getIterableHistory, getLatestMessageId, getLatestMessageIdLong, hasLatestMessage, pinMessageById, pinMessageById, purgeMessages, purgeMessages, purgeMessagesById, purgeMessagesById, purgeMessagesById, removeReactionById, removeReactionById, removeReactionById, removeReactionById, retrieveMessageById, retrieveMessageById, retrievePinnedMessages, retrieveReactionUsersById, retrieveReactionUsersById, retrieveReactionUsersById, retrieveReactionUsersById, sendFile, sendFile, sendFile, sendFile, sendMessage, sendMessage, sendMessageEmbeds, sendMessageEmbeds, sendMessageFormat, sendTyping, unpinMessageById, unpinMessageById
-
Method Details
-
isPublic
default boolean isPublic() -
getMessageCount
int getMessageCount() -
getMemberCount
int getMemberCount() -
isJoined
default boolean isJoined() -
isLocked
boolean isLocked() -
isInvitable
boolean isInvitable() -
getParentChannel
-
getParentMessageChannel
-
getSelfThreadMember
-
getThreadMembers
-
getThreadMember
-
getThreadMember
-
getThreadMemberById
-
getThreadMemberById
-
retrieveThreadMember
@Nonnull @CheckReturnValue default RestAction<ThreadMember> retrieveThreadMember(@Nonnull Member member) Load the thread-member for the specified user.
If the thread-member is already loaded it, will be retrieved fromgetThreadMemberById(long)
and immediately provided if the thread-member information is consistent. If the bot hasn't joined the thread,GatewayIntent.GUILD_MEMBERS
is required to keep the cache updated.- Parameters:
member
- The member to load the thread-member from- Returns:
RestAction
- Type:ThreadMember
- Throws:
IllegalArgumentException
- If provided with null
-
retrieveThreadMember
@Nonnull @CheckReturnValue default RestAction<ThreadMember> retrieveThreadMember(@Nonnull User user) Load the thread-member for the specified user.
If the thread-member is already loaded, it will be retrieved fromgetThreadMemberById(long)
and immediately provided if the thread-member information is consistent. If the bot hasn't joined the thread,GatewayIntent.GUILD_MEMBERS
is required to keep the cache updated.- Parameters:
user
- The user to load the thread-member from- Returns:
RestAction
- Type:ThreadMember
- Throws:
IllegalArgumentException
- If provided with null
-
retrieveThreadMemberById
@Nonnull @CheckReturnValue default RestAction<ThreadMember> retrieveThreadMemberById(@Nonnull String id) Load the thread-member for the user with the specified id.
If the thread-member is already loaded, it will be retrieved fromgetThreadMemberById(long)
and immediately provided if the thread-member information is consistent. If the bot hasn't joined the thread,GatewayIntent.GUILD_MEMBERS
is required to keep the cache updated.- Parameters:
id
- The user id to load the thread-member from- Returns:
RestAction
- Type:ThreadMember
- Throws:
IllegalArgumentException
- If the provided id is empty or nullNumberFormatException
- If the provided id is not a snowflake
-
retrieveThreadMemberById
Load the thread-member for the user with the specified id.
If the thread-member is already loaded, it will be retrieved fromgetThreadMemberById(long)
and immediately provided if the thread-member information is consistent. If the bot hasn't joined the thread,GatewayIntent.GUILD_MEMBERS
is required to keep the cache updated.- Parameters:
id
- The user id to load the thread-member from- Returns:
RestAction
- Type:ThreadMember
-
retrieveThreadMembers
-
isOwner
default boolean isOwner() -
getOwnerIdLong
long getOwnerIdLong() -
getOwnerId
-
getOwner
-
getOwnerThreadMember
-
isArchived
boolean isArchived() -
getTimeArchiveInfoLastModified
OffsetDateTime getTimeArchiveInfoLastModified() -
getAutoArchiveDuration
-
getSlowmode
int getSlowmode() -
join
-
leave
-
addThreadMemberById
-
addThreadMemberById
-
addThreadMember
-
addThreadMember
-
removeThreadMemberById
-
removeThreadMemberById
-
removeThreadMember
-
removeThreadMember
-
getManager
Description copied from interface:GuildChannel
Returns theChannelManager
for this GuildChannel.
In the ChannelManager, you can modify the name, topic and position of this GuildChannel. You modify multiple fields in one request by chaining setters before callingRestAction.queue()
.This is a lazy idempotent getter. The manager is retained after the first call. This getter is not thread-safe and would require guards by the user.
- Specified by:
getManager
in interfaceGuildChannel
- Returns:
- The ChannelManager of this GuildChannel
-
formatTo
- Specified by:
formatTo
in interfaceChannel
- Specified by:
formatTo
in interfaceFormattable
- Specified by:
formatTo
in interfaceIMentionable
-