Package net.dv8tion.jda.api.entities
Interface StageChannel
-
- All Superinterfaces:
AbstractChannel,java.lang.Comparable<GuildChannel>,java.util.Formattable,GuildChannel,IMentionable,ISnowflake,VoiceChannel
public interface StageChannel extends VoiceChannel
Represents a Stage Channel.This is a more advanced version of a
VoiceChannelthat can be used to host events with speakers and listeners.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description StageInstanceActioncreateStageInstance(java.lang.String topic)Create a newStageInstancefor this stage channel.StageInstancegetStageInstance()StageInstanceattached to this stage channel.default booleanisModerator(Member member)Whether this member is considered a moderator for this stage channel.-
Methods inherited from interface net.dv8tion.jda.api.entities.AbstractChannel
getJDA, getName, getType
-
Methods inherited from interface net.dv8tion.jda.api.entities.GuildChannel
createInvite, createPermissionOverride, delete, getGuild, getManager, getMemberPermissionOverrides, getMembers, getParent, getPermissionOverride, getPermissionOverrides, getPosition, getPositionRaw, getRolePermissionOverrides, isSynced, putPermissionOverride, retrieveInvites, upsertPermissionOverride
-
Methods inherited from interface net.dv8tion.jda.api.entities.IMentionable
formatTo, getAsMention
-
Methods inherited from interface net.dv8tion.jda.api.entities.ISnowflake
getId, getIdLong, getTimeCreated
-
Methods inherited from interface net.dv8tion.jda.api.entities.VoiceChannel
createCopy, createCopy, getBitrate, getRegion, getRegionRaw, getUserLimit
-
-
-
-
Method Detail
-
getStageInstance
@Nullable StageInstance getStageInstance()
StageInstanceattached to this stage channel.This indicates whether a stage channel is currently "live".
- Returns:
- The
StageInstanceornullif this stage is not live
-
createStageInstance
@Nonnull @CheckReturnValue StageInstanceAction createStageInstance(@Nonnull java.lang.String topic)
Create a newStageInstancefor this stage channel.Possible
ErrorResponsesinclude:STAGE_ALREADY_OPEN
If there already is an activeStageInstancefor this channelUNKNOWN_CHANNEL
If the channel was deleted
- Parameters:
topic- The topic of this stage instance, must be 1-120 characters long- Returns:
StageInstanceAction- Throws:
InsufficientPermissionException- If the self member is not a stage moderator. (SeeisModerator(Member))java.lang.IllegalArgumentException- If the topic is null, empty, or longer than 120 characters
-
isModerator
default boolean isModerator(@Nonnull Member member)Whether this member is considered a moderator for this stage channel.
Moderators can modify theStage Instanceand promote speakers. To promote a speaker you can useGuildVoiceState.inviteSpeaker()orGuildVoiceState.approveSpeaker()if they have already raised their hand (indicated byGuildVoiceState.getRequestToSpeakTimestamp()). A stage moderator can move between speaker and audience without raising their hand. This can be done withGuild.requestToSpeak()andGuild.cancelRequestToSpeak()respectively.A member is considered a stage moderator if they have these permissions in the stage channel:
- Parameters:
member- The member to check- Returns:
- True, if the provided member is a stage moderator
- Throws:
java.lang.IllegalArgumentException- If the provided member is null or not from this guild
-
-