Class Extension

java.lang.Object
org.teleight.teleightbots.extensions.Extension

public abstract class Extension extends Object

Blueprint for creating a new extension.

Each extension has a reference to its parent bot.

  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected final TelegramBot
    A reference to the bot that this extension is associated with.
  • Constructor Summary

    Constructors
    Constructor
    Description
    The constructor for the Extension class.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Method used when the extension is shut down.
    void
    Method used when the extension is started.

    Methods inherited from class Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • bot

      protected final TelegramBot bot
      A reference to the bot that this extension is associated with.
  • Constructor Details

    • Extension

      public Extension(TelegramBot bot)
      The constructor for the Extension class.
      Parameters:
      bot - The bot that this extension is associated with.
  • Method Details

    • start

      public void start()
      Method used when the extension is started.
    • shutdown

      public void shutdown()
      Method used when the extension is shut down.