Class DiscordModuleBase<CONTEXT extends DiscordCommandContext>

java.lang.Object
kboyle.oktane.core.module.ModuleBase<CONTEXT>
kboyle.oktane.discord4j.module.DiscordModuleBase<CONTEXT>
Type Parameters:
CONTEXT - The type of DiscordCommandContext to use.

public abstract class DiscordModuleBase<CONTEXT extends DiscordCommandContext> extends ModuleBase<CONTEXT>
Represents a base class to designate a class as a Discord based CommandModule.
  • Constructor Details

    • DiscordModuleBase

      public DiscordModuleBase()
  • Method Details

    • reply

      protected CommandResult reply(String content)
      Represents a reply to a Message. Does not mention anyone by default.
      Parameters:
      content - The message to send.
      Returns:
      A CommandResult representing a reply to the user.
    • reply

      protected CommandResult reply(Consumer<discord4j.core.spec.MessageCreateSpec> messageCreateSpecConsumer)
      Represents a reply to a Message. Does not mention anyone by default.
      Parameters:
      messageCreateSpecConsumer - The spec to use for the Message.
      Returns:
      A CommandResult representing a reply to the user.
    • embed

      protected CommandResult embed(Consumer<discord4j.core.spec.EmbedCreateSpec> embedCreateSpecConsumer)
      Represents an Embed reply to a Message. Does not mention anyone by default.
      Parameters:
      embedCreateSpecConsumer - The spec to use for the Embed.
      Returns:
      A CommandResult representing an Embed reply to the user.