Skip to content

Commit

Permalink
Reword other @thrown DetachedEntityException
Browse files Browse the repository at this point in the history
  • Loading branch information
freya022 committed Dec 10, 2024
1 parent b8e0737 commit 4b031a7
Show file tree
Hide file tree
Showing 4 changed files with 71 additions and 71 deletions.
42 changes: 21 additions & 21 deletions src/main/java/net/dv8tion/jda/api/entities/IPermissionHolder.java
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public interface IPermissionHolder extends ISnowflake
* <br><u>Changes to the returned set do not affect this entity directly.</u>
*
* @throws net.dv8tion.jda.api.exceptions.DetachedEntityException
* if this is a member and the bot {@link Guild#isDetached() isn't in the guild}.
* If this is a {@link Member#isDetached() detached} member
*
* @return An EnumSet of Permissions granted to this PermissionHolder.
*/
Expand All @@ -67,11 +67,11 @@ public interface IPermissionHolder extends ISnowflake
* @throws java.lang.IllegalArgumentException
* If the channel is null
* @throws net.dv8tion.jda.api.exceptions.DetachedEntityException
* if this is a role and the bot {@link Guild#isDetached() isn't in the guild}.
* If this is a {@link Role#isDetached() detached} role
* @throws net.dv8tion.jda.api.exceptions.MissingEntityInteractionPermissionsException
* if this is a member, the bot {@link Guild#isDetached() isn't in the guild},
* If this is a {@link Member#isDetached() detached} member,
* and the combination of Member and GuildChannel doesn't have permission data,
* see {@link net.dv8tion.jda.api.exceptions.MissingEntityInteractionPermissionsException MissingEntityInteractionPermissionsException}.
* see {@link net.dv8tion.jda.api.exceptions.MissingEntityInteractionPermissionsException MissingEntityInteractionPermissionsException}
*
* @return Set of Permissions granted to this Permission Holder in the specified channel.
*/
Expand All @@ -85,7 +85,7 @@ public interface IPermissionHolder extends ISnowflake
* <br><u>Changes to the returned set do not affect this entity directly.</u>
*
* @throws net.dv8tion.jda.api.exceptions.DetachedEntityException
* if this is a member and the bot {@link Guild#isDetached() isn't in the guild}.
* If this is a {@link Member#isDetached() detached} member
*
* @return EnumSet of the explicitly granted permissions
*/
Expand All @@ -105,11 +105,11 @@ public interface IPermissionHolder extends ISnowflake
* @throws java.lang.IllegalArgumentException
* If the channel is null
* @throws net.dv8tion.jda.api.exceptions.DetachedEntityException
* if this is a role and the bot {@link Guild#isDetached() isn't in the guild}.
* If this is a {@link Role#isDetached() detached} role
* @throws net.dv8tion.jda.api.exceptions.MissingEntityInteractionPermissionsException
* if this is a member, the bot {@link Guild#isDetached() isn't in the guild},
* If this is a {@link Member#isDetached() detached} member,
* and the combination of Member and GuildChannel doesn't have permission data,
* see {@link net.dv8tion.jda.api.exceptions.MissingEntityInteractionPermissionsException MissingEntityInteractionPermissionsException}.
* see {@link net.dv8tion.jda.api.exceptions.MissingEntityInteractionPermissionsException MissingEntityInteractionPermissionsException}
*
* @return EnumSet of the explicitly granted permissions in the specified channel
*/
Expand All @@ -125,7 +125,7 @@ public interface IPermissionHolder extends ISnowflake
* @throws IllegalArgumentException
* If null is provided
* @throws net.dv8tion.jda.api.exceptions.DetachedEntityException
* if this is a member and the bot {@link Guild#isDetached() isn't in the guild}.
* If this is a {@link Member#isDetached() detached} member.
*
* @return True, if all of the specified Permissions are granted to this PermissionHolder.
*/
Expand All @@ -141,7 +141,7 @@ public interface IPermissionHolder extends ISnowflake
* @throws IllegalArgumentException
* If null is provided
* @throws net.dv8tion.jda.api.exceptions.DetachedEntityException
* if this is a member and the bot {@link Guild#isDetached() isn't in the guild}.
* If this is a {@link Member#isDetached() detached} member.
*
* @return True, if all of the specified Permissions are granted to this PermissionHolder.
*
Expand All @@ -164,11 +164,11 @@ default boolean hasPermission(@Nonnull Collection<Permission> permissions)
* @throws IllegalArgumentException
* If null is provided
* @throws net.dv8tion.jda.api.exceptions.DetachedEntityException
* if this is a role and the bot {@link Guild#isDetached() isn't in the guild}.
* If this is a {@link Role#isDetached() detached} role
* @throws net.dv8tion.jda.api.exceptions.MissingEntityInteractionPermissionsException
* if this is a member, the bot {@link Guild#isDetached() isn't in the guild},
* If this is a {@link Member#isDetached() detached} member,
* and the combination of Member and GuildChannel doesn't have permission data,
* see {@link net.dv8tion.jda.api.exceptions.MissingEntityInteractionPermissionsException MissingEntityInteractionPermissionsException}.
* see {@link net.dv8tion.jda.api.exceptions.MissingEntityInteractionPermissionsException MissingEntityInteractionPermissionsException}
*
* @return True, if all of the specified Permissions are granted to this PermissionHolder in the provided GuildChannel.
*
Expand All @@ -188,11 +188,11 @@ default boolean hasPermission(@Nonnull Collection<Permission> permissions)
* @throws IllegalArgumentException
* If null is provided
* @throws net.dv8tion.jda.api.exceptions.DetachedEntityException
* if this is a role and the bot {@link Guild#isDetached() isn't in the guild}.
* If this is a {@link Role#isDetached() detached} role
* @throws net.dv8tion.jda.api.exceptions.MissingEntityInteractionPermissionsException
* if this is a member, the bot {@link Guild#isDetached() isn't in the guild},
* If this is a {@link Member#isDetached() detached} member,
* and the combination of Member and GuildChannel doesn't have permission data,
* see {@link net.dv8tion.jda.api.exceptions.MissingEntityInteractionPermissionsException MissingEntityInteractionPermissionsException}.
* see {@link net.dv8tion.jda.api.exceptions.MissingEntityInteractionPermissionsException MissingEntityInteractionPermissionsException}
*
* @return True, if all of the specified Permissions are granted to this PermissionHolder in the provided GuildChannel.
*/
Expand All @@ -212,11 +212,11 @@ default boolean hasPermission(@Nonnull GuildChannel channel, @Nonnull Collection
* @throws IllegalArgumentException
* If null is provided
* @throws net.dv8tion.jda.api.exceptions.DetachedEntityException
* if this is a role and the bot {@link Guild#isDetached() isn't in the guild}.
* If this is a {@link Role#isDetached() detached} role
* @throws net.dv8tion.jda.api.exceptions.MissingEntityInteractionPermissionsException
* if this is a member, the bot {@link Guild#isDetached() isn't in the guild},
* If this is a {@link Member#isDetached() detached} member,
* and the combination of Member and GuildChannel doesn't have permission data,
* see {@link net.dv8tion.jda.api.exceptions.MissingEntityInteractionPermissionsException MissingEntityInteractionPermissionsException}.
* see {@link net.dv8tion.jda.api.exceptions.MissingEntityInteractionPermissionsException MissingEntityInteractionPermissionsException}
*
* @return True, if the PermissionHolder has access
*/
Expand All @@ -243,7 +243,7 @@ default boolean hasAccess(@Nonnull GuildChannel channel)
* @throws IllegalArgumentException
* If either of the channels is null or not from the same guild as this permission holder
* @throws net.dv8tion.jda.api.exceptions.DetachedEntityException
* if the bot {@link Guild#isDetached() isn't in the guild}.
* If this entity is {@link net.dv8tion.jda.api.entities.detached.IDetachableEntity#isDetached() detached}
*
* @return True, if the channels can be synced
*/
Expand All @@ -261,7 +261,7 @@ default boolean hasAccess(@Nonnull GuildChannel channel)
* @throws IllegalArgumentException
* If the channel is null or not from the same guild as this permission holder
* @throws net.dv8tion.jda.api.exceptions.DetachedEntityException
* if the bot {@link Guild#isDetached() isn't in the guild}.
* If this entity is {@link net.dv8tion.jda.api.entities.detached.IDetachableEntity#isDetached() detached}
*
* @return True, if the channel can be synced
*/
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/net/dv8tion/jda/api/entities/Role.java
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ public interface Role extends IMentionable, IPermissionHolder, IDetachableEntity
* @throws IllegalStateException
* If this role is not in the guild cache
* @throws net.dv8tion.jda.api.exceptions.DetachedEntityException
* if the bot {@link #isDetached() isn't in the guild}, use {@link #getPermissionsRaw()} instead.
* If this role is {@link #isDetached() detached}, use {@link #getPermissionsRaw()} instead
*
* @return The position of this {@link net.dv8tion.jda.api.entities.Role Role} as integer.
*/
Expand Down Expand Up @@ -188,7 +188,7 @@ public interface Role extends IMentionable, IPermissionHolder, IDetachableEntity
* @throws java.lang.IllegalArgumentException
* If the specified guild is {@code null}
* @throws net.dv8tion.jda.api.exceptions.DetachedEntityException
* if the bot {@link #isDetached() isn't in the guild} the role should be copied to.
* If the guild the role should be copied to is {@link Guild#isDetached() detached}
*
* @return {@link RoleAction RoleAction}
* <br>RoleAction with already copied values from the specified {@link net.dv8tion.jda.api.entities.Role Role}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ public interface ICopyableChannel extends GuildChannel
* @throws net.dv8tion.jda.api.exceptions.PermissionException
* If the currently logged in account does not have the {@link net.dv8tion.jda.api.Permission#MANAGE_CHANNEL MANAGE_CHANNEL} Permission
* @throws net.dv8tion.jda.api.exceptions.DetachedEntityException
* if the bot {@link #isDetached() isn't in the guild} the channel should be copied to.
* If the guild the channel should be copied to is {@link Guild#isDetached() detached}
*
* @return A specific {@link ChannelAction ChannelAction}
* <br>This action allows to set fields for the new GuildChannel before creating it!
Expand Down
Loading

0 comments on commit 4b031a7

Please sign in to comment.