Packages

trait Commands extends AnyRef

Commands

Makes a bot command-aware using a nice declarative interface

Self Type
Commands with TelegramBot
Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Commands
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  5. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native() @HotSpotIntrinsicCandidate()
  6. val cmdAt: String
  7. val cmdPrefix: String
  8. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  9. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  10. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  11. def handleUpdate(update: Update): Unit

    handleUpdate

    handleUpdate

    update

    the update to be processed. Parses messages and spawns bot commands accordingly, supports targeting specific bots. Commands and bot names are case INSENSITIVE, additional parameters are NOT. General syntax: /command[@BotUsername]* args* Assuming cmdPrefix = '/' and cmdAt = '@' here are some usage examples: To broadcast 'command' to ALL bots: /command To send 'command' (parameterless) to FooBot ONLY: /command@FooBot To send 'command' with args = ("hello", "world") to FooBot and BarBot: /command@FooBot@BarBot hello world

  12. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  13. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  14. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  15. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  16. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  17. def onCommand(command: String)(action: (Long, Seq[String]) => Unit): Unit

    on

    on

    Makes the bot able react to 'command' with the specified handler. 'action' will receive the sender (chatId) and the arguments as parameters.

  18. def replyTo(chatId: Long, disableWebPagePreview: Option[Boolean] = None, replyToMessageId: Option[Int] = None)(text: String): Future[Message]

    replyTo

    replyTo

    Handy wrapper to send text replies

  19. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  20. def toString(): String
    Definition Classes
    AnyRef → Any
  21. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  22. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  23. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable]) @Deprecated
    Deprecated

Inherited from AnyRef

Inherited from Any

Ungrouped