From bd70ed42f3971d36c01ecfc4e0572feeb5df419c Mon Sep 17 00:00:00 2001 From: freya02 <41875020+freya022@users.noreply.github.com> Date: Fri, 18 Oct 2024 14:22:06 +0200 Subject: [PATCH] Event docs --- .../events/channel/VoiceChannelEffectSendEvent.java | 4 ++++ .../soundboard/GenericSoundboardSoundEvent.java | 12 ++++++++++++ .../soundboard/SoundboardSoundCreateEvent.java | 12 ++++++++++++ .../soundboard/SoundboardSoundDeleteEvent.java | 12 ++++++++++++ .../jda/api/events/soundboard/package-info.java | 5 ++--- .../update/GenericSoundboardSoundUpdateEvent.java | 12 +++++++----- .../update/SoundboardSoundUpdateEmojiEvent.java | 12 +++++++----- .../update/SoundboardSoundUpdateNameEvent.java | 12 +++++++----- .../update/SoundboardSoundUpdateVolumeEvent.java | 12 +++++++----- .../api/events/soundboard/update/package-info.java | 5 ++--- 10 files changed, 72 insertions(+), 26 deletions(-) diff --git a/src/main/java/net/dv8tion/jda/api/events/channel/VoiceChannelEffectSendEvent.java b/src/main/java/net/dv8tion/jda/api/events/channel/VoiceChannelEffectSendEvent.java index 43c5674145..f11c390ee9 100644 --- a/src/main/java/net/dv8tion/jda/api/events/channel/VoiceChannelEffectSendEvent.java +++ b/src/main/java/net/dv8tion/jda/api/events/channel/VoiceChannelEffectSendEvent.java @@ -20,11 +20,15 @@ import net.dv8tion.jda.api.entities.channel.Channel; import net.dv8tion.jda.api.entities.channel.VoiceChannelEffect; import net.dv8tion.jda.api.entities.channel.concrete.VoiceChannel; +import net.dv8tion.jda.api.requests.GatewayIntent; import javax.annotation.Nonnull; /** * Indicates that a {@link VoiceChannelEffect voice channel effect} was sent in a {@link VoiceChannel}. + * + *
Requirements
+ * This event requires {@link GatewayIntent#GUILD_VOICE_STATES} to be enabled.
*/
public class VoiceChannelEffectSendEvent extends GenericChannelEvent
{
diff --git a/src/main/java/net/dv8tion/jda/api/events/soundboard/GenericSoundboardSoundEvent.java b/src/main/java/net/dv8tion/jda/api/events/soundboard/GenericSoundboardSoundEvent.java
index a065e6b594..21ff3890a0 100644
--- a/src/main/java/net/dv8tion/jda/api/events/soundboard/GenericSoundboardSoundEvent.java
+++ b/src/main/java/net/dv8tion/jda/api/events/soundboard/GenericSoundboardSoundEvent.java
@@ -17,12 +17,24 @@
package net.dv8tion.jda.api.events.soundboard;
import net.dv8tion.jda.api.JDA;
+import net.dv8tion.jda.api.JDABuilder;
import net.dv8tion.jda.api.entities.Guild;
import net.dv8tion.jda.api.entities.SoundboardSound;
import net.dv8tion.jda.api.events.Event;
+import net.dv8tion.jda.api.requests.GatewayIntent;
+import net.dv8tion.jda.api.utils.cache.CacheFlag;
import javax.annotation.Nonnull;
+/**
+ * Indicates that a {@link SoundboardSound} was created/deleted/updated.
+ *
+ *
Requirements
+ * These events require {@link CacheFlag#SOUNDBOARD_SOUNDS} to be enabled,
+ * which requires {@link GatewayIntent#GUILD_EMOJIS_AND_STICKERS}.
+ *
+ *
{@link JDABuilder#createLight(String) createLight(String)} disables that CacheFlag by default!
+ */
public abstract class GenericSoundboardSoundEvent extends Event
{
private final SoundboardSound soundboardSound;
diff --git a/src/main/java/net/dv8tion/jda/api/events/soundboard/SoundboardSoundCreateEvent.java b/src/main/java/net/dv8tion/jda/api/events/soundboard/SoundboardSoundCreateEvent.java
index 073b1f1f11..a12f875bec 100644
--- a/src/main/java/net/dv8tion/jda/api/events/soundboard/SoundboardSoundCreateEvent.java
+++ b/src/main/java/net/dv8tion/jda/api/events/soundboard/SoundboardSoundCreateEvent.java
@@ -17,10 +17,22 @@
package net.dv8tion.jda.api.events.soundboard;
import net.dv8tion.jda.api.JDA;
+import net.dv8tion.jda.api.JDABuilder;
import net.dv8tion.jda.api.entities.SoundboardSound;
+import net.dv8tion.jda.api.requests.GatewayIntent;
+import net.dv8tion.jda.api.utils.cache.CacheFlag;
import javax.annotation.Nonnull;
+/**
+ * Indicates that a {@link SoundboardSound} was created.
+ *
+ *
Requirements
+ * This event require {@link CacheFlag#SOUNDBOARD_SOUNDS} to be enabled,
+ * which requires {@link GatewayIntent#GUILD_EMOJIS_AND_STICKERS}.
+ *
+ *
{@link JDABuilder#createLight(String) createLight(String)} disables that CacheFlag by default!
+ */
public class SoundboardSoundCreateEvent extends GenericSoundboardSoundEvent
{
public SoundboardSoundCreateEvent(@Nonnull JDA api, long responseNumber, @Nonnull SoundboardSound soundboardSound)
diff --git a/src/main/java/net/dv8tion/jda/api/events/soundboard/SoundboardSoundDeleteEvent.java b/src/main/java/net/dv8tion/jda/api/events/soundboard/SoundboardSoundDeleteEvent.java
index 9828e5b70c..3bc1af2024 100644
--- a/src/main/java/net/dv8tion/jda/api/events/soundboard/SoundboardSoundDeleteEvent.java
+++ b/src/main/java/net/dv8tion/jda/api/events/soundboard/SoundboardSoundDeleteEvent.java
@@ -17,10 +17,22 @@
package net.dv8tion.jda.api.events.soundboard;
import net.dv8tion.jda.api.JDA;
+import net.dv8tion.jda.api.JDABuilder;
import net.dv8tion.jda.api.entities.SoundboardSound;
+import net.dv8tion.jda.api.requests.GatewayIntent;
+import net.dv8tion.jda.api.utils.cache.CacheFlag;
import javax.annotation.Nonnull;
+/**
+ * Indicates that a {@link SoundboardSound} was deleted.
+ *
+ *
Requirements
+ * This event require {@link CacheFlag#SOUNDBOARD_SOUNDS} to be enabled,
+ * which requires {@link GatewayIntent#GUILD_EMOJIS_AND_STICKERS}.
+ *
+ *
{@link JDABuilder#createLight(String) createLight(String)} disables that CacheFlag by default!
+ */
public class SoundboardSoundDeleteEvent extends GenericSoundboardSoundEvent
{
public SoundboardSoundDeleteEvent(@Nonnull JDA api, long responseNumber, @Nonnull SoundboardSound soundboardSound)
diff --git a/src/main/java/net/dv8tion/jda/api/events/soundboard/package-info.java b/src/main/java/net/dv8tion/jda/api/events/soundboard/package-info.java
index 0cf5c8c3ea..0b04068923 100644
--- a/src/main/java/net/dv8tion/jda/api/events/soundboard/package-info.java
+++ b/src/main/java/net/dv8tion/jda/api/events/soundboard/package-info.java
@@ -19,9 +19,8 @@
* and {@link net.dv8tion.jda.api.events.soundboard.SoundboardSoundDeleteEvent deleted soundboard sounds}.
*
*
Requirements
- *
- *
These events require the {@link net.dv8tion.jda.api.utils.cache.CacheFlag#SOUNDBOARD_SOUNDS SOUNDBOARD_SOUNDS} CacheFlag to be enabled, which requires
- * the {@link net.dv8tion.jda.api.requests.GatewayIntent#GUILD_EMOJIS_AND_STICKERS GUILD_EMOJIS_AND_STICKERS} intent.
+ * These events require {@link net.dv8tion.jda.api.utils.cache.CacheFlag#SOUNDBOARD_SOUNDS} to be enabled,
+ * which requires {@link net.dv8tion.jda.api.requests.GatewayIntent#GUILD_EMOJIS_AND_STICKERS}.
*
*
{@link net.dv8tion.jda.api.JDABuilder#createLight(String) createLight(String)} disables that CacheFlag by default!
*/
diff --git a/src/main/java/net/dv8tion/jda/api/events/soundboard/update/GenericSoundboardSoundUpdateEvent.java b/src/main/java/net/dv8tion/jda/api/events/soundboard/update/GenericSoundboardSoundUpdateEvent.java
index 6b5cb967bd..4cf0edc9e1 100644
--- a/src/main/java/net/dv8tion/jda/api/events/soundboard/update/GenericSoundboardSoundUpdateEvent.java
+++ b/src/main/java/net/dv8tion/jda/api/events/soundboard/update/GenericSoundboardSoundUpdateEvent.java
@@ -17,22 +17,24 @@
package net.dv8tion.jda.api.events.soundboard.update;
import net.dv8tion.jda.api.JDA;
+import net.dv8tion.jda.api.JDABuilder;
import net.dv8tion.jda.api.entities.SoundboardSound;
import net.dv8tion.jda.api.events.UpdateEvent;
import net.dv8tion.jda.api.events.soundboard.GenericSoundboardSoundEvent;
+import net.dv8tion.jda.api.requests.GatewayIntent;
+import net.dv8tion.jda.api.utils.cache.CacheFlag;
import javax.annotation.Nonnull;
import javax.annotation.Nullable;
/**
- * Indicates that a {@link SoundboardSound soundboard sound} was updated.
+ * Indicates that a {@link SoundboardSound} was updated.
*
*
Requirements
+ * These events require {@link CacheFlag#SOUNDBOARD_SOUNDS} to be enabled,
+ * which requires {@link GatewayIntent#GUILD_EMOJIS_AND_STICKERS}.
*
- *
These events require the {@link net.dv8tion.jda.api.utils.cache.CacheFlag#SOUNDBOARD_SOUNDS SOUNDBOARD_SOUNDS} CacheFlag to be enabled, which requires
- * the {@link net.dv8tion.jda.api.requests.GatewayIntent#GUILD_EMOJIS_AND_STICKERS GUILD_EMOJIS_AND_STICKERS} intent.
- *
- * Can be used to retrieve the old emoji
+ * Can be used to retrieve the old emoji.
*
* Requirements This event requires the {@link net.dv8tion.jda.api.utils.cache.CacheFlag#SOUNDBOARD_SOUNDS SOUNDBOARD_SOUNDS} CacheFlag to be enabled, which requires
- * the {@link net.dv8tion.jda.api.requests.GatewayIntent#GUILD_EMOJIS_AND_STICKERS GUILD_EMOJIS_AND_STICKERS} intent.
- *
- * Identifier: {@value IDENTIFIER}
*/
diff --git a/src/main/java/net/dv8tion/jda/api/events/soundboard/update/SoundboardSoundUpdateNameEvent.java b/src/main/java/net/dv8tion/jda/api/events/soundboard/update/SoundboardSoundUpdateNameEvent.java
index 53e7fe5dcb..e0ddbe21e3 100644
--- a/src/main/java/net/dv8tion/jda/api/events/soundboard/update/SoundboardSoundUpdateNameEvent.java
+++ b/src/main/java/net/dv8tion/jda/api/events/soundboard/update/SoundboardSoundUpdateNameEvent.java
@@ -17,21 +17,23 @@
package net.dv8tion.jda.api.events.soundboard.update;
import net.dv8tion.jda.api.JDA;
+import net.dv8tion.jda.api.JDABuilder;
import net.dv8tion.jda.api.entities.SoundboardSound;
+import net.dv8tion.jda.api.requests.GatewayIntent;
+import net.dv8tion.jda.api.utils.cache.CacheFlag;
import javax.annotation.Nonnull;
/**
* Indicates that the name of a {@link SoundboardSound soundboard sound} changed.
*
- * Can be used to retrieve the old name
+ * Can be used to retrieve the old name.
*
* Requirements This event requires the {@link net.dv8tion.jda.api.utils.cache.CacheFlag#SOUNDBOARD_SOUNDS SOUNDBOARD_SOUNDS} CacheFlag to be enabled, which requires
- * the {@link net.dv8tion.jda.api.requests.GatewayIntent#GUILD_EMOJIS_AND_STICKERS GUILD_EMOJIS_AND_STICKERS} intent.
- *
- * Identifier: {@value IDENTIFIER}
*/
diff --git a/src/main/java/net/dv8tion/jda/api/events/soundboard/update/SoundboardSoundUpdateVolumeEvent.java b/src/main/java/net/dv8tion/jda/api/events/soundboard/update/SoundboardSoundUpdateVolumeEvent.java
index 8e8eb18742..fd3ee8dc03 100644
--- a/src/main/java/net/dv8tion/jda/api/events/soundboard/update/SoundboardSoundUpdateVolumeEvent.java
+++ b/src/main/java/net/dv8tion/jda/api/events/soundboard/update/SoundboardSoundUpdateVolumeEvent.java
@@ -17,21 +17,23 @@
package net.dv8tion.jda.api.events.soundboard.update;
import net.dv8tion.jda.api.JDA;
+import net.dv8tion.jda.api.JDABuilder;
import net.dv8tion.jda.api.entities.SoundboardSound;
+import net.dv8tion.jda.api.requests.GatewayIntent;
+import net.dv8tion.jda.api.utils.cache.CacheFlag;
import javax.annotation.Nonnull;
/**
* Indicates that the volume of a {@link SoundboardSound soundboard sound} changed.
*
- * Can be used to retrieve the old volume
+ * Can be used to retrieve the old volume.
*
* Requirements This event requires the {@link net.dv8tion.jda.api.utils.cache.CacheFlag#SOUNDBOARD_SOUNDS SOUNDBOARD_SOUNDS} CacheFlag to be enabled, which requires
- * the {@link net.dv8tion.jda.api.requests.GatewayIntent#GUILD_EMOJIS_AND_STICKERS GUILD_EMOJIS_AND_STICKERS} intent.
- *
- * Identifier: {@value IDENTIFIER}
*/
diff --git a/src/main/java/net/dv8tion/jda/api/events/soundboard/update/package-info.java b/src/main/java/net/dv8tion/jda/api/events/soundboard/update/package-info.java
index 5a26ea9abc..8083e7d57e 100644
--- a/src/main/java/net/dv8tion/jda/api/events/soundboard/update/package-info.java
+++ b/src/main/java/net/dv8tion/jda/api/events/soundboard/update/package-info.java
@@ -18,9 +18,8 @@
* Events that track updates for existing {@link net.dv8tion.jda.api.entities.SoundboardSound SoundboardSounds}
*
* Requirements These events require the {@link net.dv8tion.jda.api.utils.cache.CacheFlag#SOUNDBOARD_SOUNDS SOUNDBOARD_SOUNDS} CacheFlag to be enabled, which requires
- * the {@link net.dv8tion.jda.api.requests.GatewayIntent#GUILD_EMOJIS_AND_STICKERS GUILD_EMOJIS_AND_STICKERS} intent.
+ * These events require {@link net.dv8tion.jda.api.utils.cache.CacheFlag#SOUNDBOARD_SOUNDS} to be enabled,
+ * which requires {@link net.dv8tion.jda.api.requests.GatewayIntent#GUILD_EMOJIS_AND_STICKERS}.
*
*
{@link net.dv8tion.jda.api.JDABuilder#createLight(String) createLight(String)} disables that CacheFlag by default!
+ *
{@link JDABuilder#createLight(String) createLight(String)} disables that CacheFlag by default!
*/
public abstract class GenericSoundboardSoundUpdateEvent
+ * This event require {@link CacheFlag#SOUNDBOARD_SOUNDS} to be enabled,
+ * which requires {@link GatewayIntent#GUILD_EMOJIS_AND_STICKERS}.
*
- *
{@link net.dv8tion.jda.api.JDABuilder#createLight(String) createLight(String)} disables that CacheFlag by default!
+ *
{@link JDABuilder#createLight(String) createLight(String)} disables that CacheFlag by default!
*
*
+ * This event require {@link CacheFlag#SOUNDBOARD_SOUNDS} to be enabled,
+ * which requires {@link GatewayIntent#GUILD_EMOJIS_AND_STICKERS}.
*
- *
{@link net.dv8tion.jda.api.JDABuilder#createLight(String) createLight(String)} disables that CacheFlag by default!
+ *
{@link JDABuilder#createLight(String) createLight(String)} disables that CacheFlag by default!
*
*
+ * This event require {@link CacheFlag#SOUNDBOARD_SOUNDS} to be enabled,
+ * which requires {@link GatewayIntent#GUILD_EMOJIS_AND_STICKERS}.
*
- *
{@link net.dv8tion.jda.api.JDABuilder#createLight(String) createLight(String)} disables that CacheFlag by default!
+ *
{@link JDABuilder#createLight(String) createLight(String)} disables that CacheFlag by default!
*
*
- *
- *
{@link net.dv8tion.jda.api.JDABuilder#createLight(String) createLight(String)} disables that CacheFlag by default!
*/