Class ForwardMessage

All Implemented Interfaces:
Validable

public class ForwardMessage extends BotApiMethodMessage
Version:
1.0 Use this method to forward messages of any kind. Service messages can't be forwarded. On success, the sent Message is returned.
Author:
Ruben Bermudez
  • Field Details

  • Constructor Details

    • ForwardMessage

      public ForwardMessage()
  • Method Details

    • setChatId

      public void setChatId(@NonNull @NonNull Long chatId)
    • setFromChatId

      public void setFromChatId(@NonNull @NonNull Long fromChatId)
    • validate

      public void validate() throws TelegramApiValidationException
      Description copied from interface: Validable
      Validates that mandatory fields are filled and optional objects
      Throws:
      TelegramApiValidationException - If any mandatory field is empty
    • getMethod

      public String getMethod()
      Description copied from class: BotApiMethod
      Getter for method path (that is the same as method name)
      Specified by:
      getMethod in class BotApiMethod<Message>
      Returns:
      Method path