Package net.dv8tion.jda.api.audit
Enum AuditLogOption
- java.lang.Object
-
- java.lang.Enum<AuditLogOption>
-
- net.dv8tion.jda.api.audit.AuditLogOption
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<AuditLogOption>
public enum AuditLogOption extends java.lang.Enum<AuditLogOption>
Enum constants for possible options
Providing detailed description of possible occasions and expected types.The expected types are not guaranteed to be accurate!
- See Also:
- Optional Audit Entry Info
-
-
Enum Constant Summary
Enum Constants Enum Constant Description CHANNEL
Possible secondary target of anActionType
such as:ActionType.MEMBER_VOICE_MOVE
ActionType.MESSAGE_PIN
ActionType.MESSAGE_UNPIN
ActionType.MESSAGE_DELETE
Use withGuild.getGuildChannelById(String)
.COUNT
Possible detail forActionType.MESSAGE_DELETE
ActionType.MESSAGE_BULK_DELETE
ActionType.MEMBER_VOICE_KICK
ActionType.MEMBER_VOICE_MOVE
describing the amount of targeted entities.DELETE_MEMBER_DAYS
Possible option ofActionType.PRUNE
describing the period of inactivity for that prune.ID
This is sometimes visible forActionTypes
which create a new entity.MEMBERS_REMOVED
Possible option ofActionType.PRUNE
describing the amount of kicked members for that prune.MESSAGE
Possible message id for actions of typeActionType.MESSAGE_PIN
andActionType.MESSAGE_UNPIN
.ROLE
Possible secondary target of anActionType
such asActionType.CHANNEL_OVERRIDE_CREATE
Use withGuild.getRoleById(String)
ROLE_NAME
Possible name of the role if the target type isTargetType.ROLE
TYPE
Possible option indicating the type of an entity.USER
Possible secondary target of anActionType
such asActionType.CHANNEL_OVERRIDE_CREATE
Use withJDA.getUserById(String)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getKey()
Key used inAuditLogEntry.getOptionByName(String)
java.lang.String
toString()
static AuditLogOption
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static AuditLogOption[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
COUNT
public static final AuditLogOption COUNT
Possible detail forActionType.MESSAGE_DELETE
ActionType.MESSAGE_BULK_DELETE
ActionType.MEMBER_VOICE_KICK
ActionType.MEMBER_VOICE_MOVE
Use withInteger.parseInt(String)
.Expected type: String
-
MESSAGE
public static final AuditLogOption MESSAGE
Possible message id for actions of typeActionType.MESSAGE_PIN
andActionType.MESSAGE_UNPIN
.
Use withMessageChannel.retrieveMessageById(String)
.Expected type: String
-
CHANNEL
public static final AuditLogOption CHANNEL
Possible secondary target of anActionType
such as:ActionType.MEMBER_VOICE_MOVE
ActionType.MESSAGE_PIN
ActionType.MESSAGE_UNPIN
ActionType.MESSAGE_DELETE
Guild.getGuildChannelById(String)
.Expected type: String
-
USER
public static final AuditLogOption USER
Possible secondary target of anActionType
such asActionType.CHANNEL_OVERRIDE_CREATE
Use withJDA.getUserById(String)
Expected type: String
-
ROLE
public static final AuditLogOption ROLE
Possible secondary target of anActionType
such asActionType.CHANNEL_OVERRIDE_CREATE
Use withGuild.getRoleById(String)
Expected type: String
-
ROLE_NAME
public static final AuditLogOption ROLE_NAME
Possible name of the role if the target type isTargetType.ROLE
Expected type: String
-
TYPE
public static final AuditLogOption TYPE
Possible option indicating the type of an entity.
Maybe forActionType.CHANNEL_OVERRIDE_CREATE
orActionType.CHANNEL_CREATE
.Expected type: String or Integer
This type depends on the action taken place.
-
ID
public static final AuditLogOption ID
This is sometimes visible forActionTypes
which create a new entity.
Use with designatedgetXById
method.Expected type: String
-
DELETE_MEMBER_DAYS
public static final AuditLogOption DELETE_MEMBER_DAYS
Possible option ofActionType.PRUNE
describing the period of inactivity for that prune.Expected type: int
-
MEMBERS_REMOVED
public static final AuditLogOption MEMBERS_REMOVED
Possible option ofActionType.PRUNE
describing the amount of kicked members for that prune.Expected type: int
-
-
Method Detail
-
values
public static AuditLogOption[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (AuditLogOption c : AuditLogOption.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static AuditLogOption valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
getKey
public java.lang.String getKey()
Key used inAuditLogEntry.getOptionByName(String)
- Returns:
- Key for this option
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Enum<AuditLogOption>
-
-