Interface ICategorizableChannelManager<T extends ICategorizableChannel,M extends ICategorizableChannelManager<T,M>>
- Type Parameters:
T- The channel typeM- The manager type
- All Superinterfaces:
AuditableRestAction<Void>,ChannelManager<T,,M> IPermissionContainerManager<T,,M> IPositionableChannelManager<T,,M> Manager<M>,RestAction<Void>
- All Known Subinterfaces:
AudioChannelManager<T,,M> ForumChannelManager,MediaChannelManager,NewsChannelManager,StageChannelManager,StandardGuildChannelManager<T,,M> StandardGuildMessageChannelManager<T,,M> TextChannelManager,VoiceChannelManager
public interface ICategorizableChannelManager<T extends ICategorizableChannel,M extends ICategorizableChannelManager<T,M>>
extends ChannelManager<T,M>, IPermissionContainerManager<T,M>, IPositionableChannelManager<T,M>
Manager abstraction to set the
Parent Category of a categorizable channel.-
Field Summary
Fields inherited from interface net.dv8tion.jda.api.requests.restaction.AuditableRestAction
MAX_REASON_LENGTHFields inherited from interface net.dv8tion.jda.api.managers.channel.ChannelManager
APPLIED_TAGS, ARCHIVED, AUTO_ARCHIVE_DURATION, AVAILABLE_TAGS, BITRATE, DEFAULT_LAYOUT, DEFAULT_REACTION, DEFAULT_SORT_ORDER, DEFAULT_THREAD_SLOWMODE, HIDE_MEDIA_DOWNLOAD_OPTIONS, INVITEABLE, LOCKED, NAME, NSFW, PARENT, PERMISSION, PINNED, POSITION, REGION, REQUIRE_TAG, SLOWMODE, TOPIC, TYPE, USERLIMIT -
Method Summary
Modifier and TypeMethodDescriptionSets theParent Categoryof the selectedGuildChannel.default Msync()Syncs allPermissionOverridesof this GuildChannel with its parent (Category).sync(IPermissionContainer syncSource) Syncs allPermissionOverridesof this GuildChannel with the given (GuildChannel).Methods inherited from interface net.dv8tion.jda.api.requests.restaction.AuditableRestAction
reasonMethods inherited from interface net.dv8tion.jda.api.managers.channel.ChannelManager
getChannel, getGuild, reset, reset, setNameMethods inherited from interface net.dv8tion.jda.api.managers.channel.attribute.IPermissionContainerManager
clearOverridesAdded, clearOverridesRemoved, putMemberPermissionOverride, putMemberPermissionOverride, putPermissionOverride, putPermissionOverride, putRolePermissionOverride, putRolePermissionOverride, removePermissionOverride, removePermissionOverrideMethods inherited from interface net.dv8tion.jda.api.managers.channel.attribute.IPositionableChannelManager
setPositionMethods inherited from interface net.dv8tion.jda.api.managers.Manager
deadline, reset, setCheck, timeoutMethods inherited from interface net.dv8tion.jda.api.requests.RestAction
addCheck, and, and, complete, complete, completeAfter, delay, delay, delay, delay, flatMap, flatMap, getCheck, getJDA, map, mapToResult, onErrorFlatMap, onErrorFlatMap, onErrorMap, onErrorMap, onSuccess, queue, queue, queue, queueAfter, queueAfter, queueAfter, queueAfter, queueAfter, queueAfter, submit, submit, submitAfter, submitAfter, zip
-
Method Details
-
setParent
Sets theParent Categoryof the selectedGuildChannel.- Parameters:
category- The new parent for the selectedGuildChannel- Returns:
- ChannelManager for chaining convenience
- Throws:
IllegalStateException- If the target is a category itselfIllegalArgumentException- If the provided category is not from the same Guild- Since:
- 3.4.0
-
sync
Syncs allPermissionOverridesof this GuildChannel with its parent (Category).After this operation, all
PermissionOverrideswill be exactly the same as the ones from the parent.
That means that all current PermissionOverrides are lost!This behaves as if calling
sync(IPermissionContainer)with this GuildChannel'sICategorizableChannel.getParentCategory()Parent}.- Returns:
- ChannelManager for chaining convenience
- Throws:
IllegalStateException- If this GuildChannel has no parentInsufficientPermissionException- If the currently logged in account does not havePermission.MANAGE_PERMISSIONSin this channel orIPermissionHolder.canSync(IPermissionContainer, IPermissionContainer)is false for the self member.- See Also:
-
sync
Syncs allPermissionOverridesof this GuildChannel with the given (GuildChannel).After this operation, all
PermissionOverrideswill be exactly the same as the ones from the syncSource.
That means that all current PermissionOverrides are lost!This will only work for Channels of the same
Guild!.- Parameters:
syncSource- The GuildChannel from where all PermissionOverrides should be copied from- Returns:
- ChannelManager for chaining convenience
- Throws:
IllegalArgumentException- If the given snySource isnull, this GuildChannel or from a different Guild.InsufficientPermissionException- If the currently logged in account does not havePermission.MANAGE_PERMISSIONSin this channel orIPermissionHolder.canSync(IPermissionContainer, IPermissionContainer)is false for the self member.- See Also:
-