Class RoleUpdatePermissionsEvent
- java.lang.Object
-
- net.dv8tion.jda.api.events.Event
-
- net.dv8tion.jda.api.events.role.GenericRoleEvent
-
- net.dv8tion.jda.api.events.role.update.GenericRoleUpdateEvent<java.util.EnumSet<Permission>>
-
- net.dv8tion.jda.api.events.role.update.RoleUpdatePermissionsEvent
-
- All Implemented Interfaces:
GenericEvent
,UpdateEvent<Role,java.util.EnumSet<Permission>>
public class RoleUpdatePermissionsEvent extends GenericRoleUpdateEvent<java.util.EnumSet<Permission>>
Indicates that aRole
updated its permissions.Can be used to retrieve the old permissions.
Identifier:
permission
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
IDENTIFIER
-
Constructor Summary
Constructors Constructor Description RoleUpdatePermissionsEvent(JDA api, long responseNumber, Role role, long oldPermissionsRaw)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.EnumSet<Permission>
getNewPermissions()
The new permissionslong
getNewPermissionsRaw()
The new permissionsjava.util.EnumSet<Permission>
getNewValue()
The new valuejava.util.EnumSet<Permission>
getOldPermissions()
The old permissionslong
getOldPermissionsRaw()
The old permissionsjava.util.EnumSet<Permission>
getOldValue()
The old value-
Methods inherited from class net.dv8tion.jda.api.events.role.update.GenericRoleUpdateEvent
getEntity, getPropertyIdentifier, toString
-
Methods inherited from class net.dv8tion.jda.api.events.role.GenericRoleEvent
getGuild, getRole
-
Methods inherited from class net.dv8tion.jda.api.events.Event
getJDA, getResponseNumber
-
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface net.dv8tion.jda.api.events.GenericEvent
getJDA, getResponseNumber
-
Methods inherited from interface net.dv8tion.jda.api.events.UpdateEvent
getEntityType
-
-
-
-
Field Detail
-
IDENTIFIER
public static final java.lang.String IDENTIFIER
- See Also:
- Constant Field Values
-
-
Method Detail
-
getOldPermissions
@Nonnull public java.util.EnumSet<Permission> getOldPermissions()
The old permissions- Returns:
- The old permissions
-
getOldPermissionsRaw
public long getOldPermissionsRaw()
The old permissions- Returns:
- The old permissions
-
getNewPermissions
@Nonnull public java.util.EnumSet<Permission> getNewPermissions()
The new permissions- Returns:
- The new permissions
-
getNewPermissionsRaw
public long getNewPermissionsRaw()
The new permissions- Returns:
- The new permissions
-
getOldValue
@Nonnull public java.util.EnumSet<Permission> getOldValue()
Description copied from interface:UpdateEvent
The old value- Specified by:
getOldValue
in interfaceUpdateEvent<Role,java.util.EnumSet<Permission>>
- Overrides:
getOldValue
in classGenericRoleUpdateEvent<java.util.EnumSet<Permission>>
- Returns:
- The old value
-
getNewValue
@Nonnull public java.util.EnumSet<Permission> getNewValue()
Description copied from interface:UpdateEvent
The new value- Specified by:
getNewValue
in interfaceUpdateEvent<Role,java.util.EnumSet<Permission>>
- Overrides:
getNewValue
in classGenericRoleUpdateEvent<java.util.EnumSet<Permission>>
- Returns:
- The new value
-
-