Class IntegrationPrivilege

java.lang.Object
net.dv8tion.jda.api.interactions.commands.privileges.IntegrationPrivilege
All Implemented Interfaces:
ISnowflake

public class IntegrationPrivilege extends Object implements ISnowflake
Privilege used to restrict access to a command within a Guild.

Moderators of a Guild can create these privileges inside the Integrations Menu

See Also:
  • Constructor Details

  • Method Details

    • targetsEveryone

      public boolean targetsEveryone()
      Whether this IntegrationPrivilege targets the @everyone Role
      Returns:
      True, if this IntegrationPrivilege targets the @everyone Role
    • targetsAllChannels

      public boolean targetsAllChannels()
      Whether this IntegrationPrivilege targets "All channels"
      Returns:
      True, if this IntegrationPrivilege targets all channels
    • getIdLong

      public long getIdLong()
      Description copied from interface: ISnowflake
      The Snowflake id of this entity. This is unique to every entity and will never change.
      Specified by:
      getIdLong in interface ISnowflake
      Returns:
      Long containing the Id.
    • getType

      The IntegrationPrivilege.Type of entity this privilege is applied to.
      Returns:
      The target IntegrationPrivilege.Type
    • getGuild

      @Nonnull public Guild getGuild()
      The Guild this IntegrationPrivilege was created in.
      Returns:
      the guild in which this IntegrationPrivilege was created in.
    • isEnabled

      public boolean isEnabled()
      True if this privilege is granting access to the command
      Returns:
      Whether this privilege grants access
    • isDisabled

      public boolean isDisabled()
      True if this privilege is denying access to the command
      Returns:
      Whether this privilege denies access
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object