Interface IInviteContainer
- All Superinterfaces:
Channel
,Comparable<GuildChannel>
,Formattable
,GuildChannel
,IMentionable
,ISnowflake
- All Known Subinterfaces:
AudioChannel
,AudioChannelUnion
,DefaultGuildChannelUnion
,ForumChannel
,MediaChannel
,NewsChannel
,StageChannel
,StandardGuildChannel
,StandardGuildMessageChannel
,TextChannel
,VoiceChannel
Represents a
GuildChannel
that can be the target of a Guild's invite.
Invites have to be targeted at exactly one IInviteContainer
, which will open when the invite is used (unless restricted by permissions).
-
Field Summary
Fields inherited from interface net.dv8tion.jda.api.entities.channel.Channel
MAX_NAME_LENGTH
Fields inherited from interface net.dv8tion.jda.api.entities.channel.middleman.GuildChannel
JUMP_URL
-
Method Summary
Modifier and TypeMethodDescriptionCreates a newInviteAction
which can be used to create a newInvite
.Returns all invites for this channel.Methods inherited from interface net.dv8tion.jda.api.entities.channel.Channel
formatTo, getAsMention, getFlags, getJDA, getName, getType
Methods inherited from interface java.lang.Comparable
compareTo
Methods inherited from interface net.dv8tion.jda.api.entities.channel.middleman.GuildChannel
delete, getGuild, getJumpUrl, getManager, getPermissionContainer
Methods inherited from interface net.dv8tion.jda.api.entities.ISnowflake
getId, getIdLong, getTimeCreated
-
Method Details
-
createInvite
Creates a newInviteAction
which can be used to create a newInvite
.
RequiresCREATE_INSTANT_INVITE
in this channel.- Returns:
- A new
InviteAction
- Throws:
InsufficientPermissionException
- If the account does not haveCREATE_INSTANT_INVITE
in this channelIllegalArgumentException
- If this is an instance of aCategory
- See Also:
-
retrieveInvites
Returns all invites for this channel.
RequiresMANAGE_CHANNEL
in this channel. Will throw anInsufficientPermissionException
otherwise.- Returns:
RestAction
- Type: List<Invite
>
The list of expanded Invite objects- Throws:
InsufficientPermissionException
- if the account does not haveMANAGE_CHANNEL
in this channel- See Also:
-