Package discord4j.core.spec.legacy
Class LegacyAuditLogQuerySpec
- java.lang.Object
-
- discord4j.core.spec.legacy.LegacyAuditLogQuerySpec
-
- All Implemented Interfaces:
LegacySpec<Map<String,Object>>
public final class LegacyAuditLogQuerySpec extends Object implements LegacySpec<Map<String,Object>>
A spec used to query audit log entries that match the specified filter.
-
-
Constructor Summary
Constructors Constructor Description LegacyAuditLogQuerySpec()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Map<String,Object>
asRequest()
LegacyAuditLogQuerySpec
setActionType(ActionType actionType)
Sets the query to return entries where the action type is the same as the one provided.LegacyAuditLogQuerySpec
setBefore(Snowflake beforeId)
Sets the query to return entries before a certain entry id.LegacyAuditLogQuerySpec
setLimit(int limit)
Sets the query to return a max of entries.LegacyAuditLogQuerySpec
setResponsibleUser(Snowflake userId)
Sets the query to only return entries where the user specified is responsible for the action.
-
-
-
Method Detail
-
setResponsibleUser
public LegacyAuditLogQuerySpec setResponsibleUser(Snowflake userId)
Sets the query to only return entries where the user specified is responsible for the action.- Parameters:
userId
- TheSnowflake
of the responsible user to filter by.- Returns:
- This spec.
-
setActionType
public LegacyAuditLogQuerySpec setActionType(ActionType actionType)
Sets the query to return entries where the action type is the same as the one provided.- Parameters:
actionType
- TheActionType
of the audit log entries to filter by.- Returns:
- This spec.
-
setBefore
public LegacyAuditLogQuerySpec setBefore(Snowflake beforeId)
Sets the query to return entries before a certain entry id.- Parameters:
beforeId
- TheSnowflake
of the audit log id to filter by before of.- Returns:
- This spec.
-
setLimit
public LegacyAuditLogQuerySpec setLimit(int limit)
Sets the query to return a max of entries.- Parameters:
limit
- The limit of the audit log entries to filter by.- Returns:
- This spec.
-
-