Package discord4j.core.object.audit
Class AuditLogPart
java.lang.Object
discord4j.core.object.audit.AuditLogPart
A part of a guild's audit logs. This holds all of the webhooks, users, and audit log entries for a portion of
a guild's audit log.
-
Constructor Summary
ConstructorDescriptionAuditLogPart
(long guildId, GatewayDiscordClient gateway, discord4j.discordjson.json.AuditLogData data) -
Method Summary
Modifier and TypeMethodDescriptioncombine
(AuditLogPart other) Combines this portion of the audit log with another portion.Get the auto mod rules that are involved in the entries of this portion of the audit log.Gets the entries in this portion of the audit log.Gets the ID of the guild associated with this audit log.getUserById
(Snowflake userId) Gets a user involved in the entries of this portion of the audit log by ID.getUsers()
Get the users that are involved in the entries of this portion of the audit log.getWebhookById
(Snowflake webhookId) Gets a webhook involved in the entries of this portion of the audit log by ID.Get the webhooks that are involved in the entries of this portion of the audit log.
-
Constructor Details
-
AuditLogPart
public AuditLogPart(long guildId, GatewayDiscordClient gateway, discord4j.discordjson.json.AuditLogData data)
-
-
Method Details
-
getAutoModRules
Get the auto mod rules that are involved in the entries of this portion of the audit log.- Returns:
- The auto mod rules that are involved in the entries of this portion of the audit log.
-
getWebhooks
Get the webhooks that are involved in the entries of this portion of the audit log.- Returns:
- The webhooks that are involved in the entries of this portion of the audit log.
-
getUsers
Get the users that are involved in the entries of this portion of the audit log.- Returns:
- The users that are involved in the entries of this portion of the audit log.
-
getEntries
Gets the entries in this portion of the audit log.- Returns:
- The entries in this portion of the audit log.
-
getWebhookById
Gets a webhook involved in the entries of this portion of the audit log by ID.- Parameters:
webhookId
- The ID of the webhook.- Returns:
- The webhook with the given ID, if present.
-
getUserById
Gets a user involved in the entries of this portion of the audit log by ID.- Parameters:
userId
- The ID of the user.- Returns:
- The user with the given ID, if present.
-
getGuildId
Gets the ID of the guild associated with this audit log.- Returns:
- The ID of the guild associated with this audit log.
-
combine
Combines this portion of the audit log with another portion.- Parameters:
other
- The other portion to combine with.- Returns:
- A new
AuditLogPart
that contains all of the webhooks, users, and entries from both parts.
-