Module tdlight.api

Class TdApi.SendMessage

Enclosing class:
TdApi

public static final class TdApi.SendMessage extends TdApi.Function<TdApi.Message>
Sends a message. Returns the sent message.

Returns Message

  • Field Details

    • chatId

      public long chatId
      Target chat.
    • messageThreadId

      public long messageThreadId
      If not 0, a message thread identifier in which the message will be sent.
    • replyTo

      public TdApi.MessageReplyTo replyTo
      Identifier of the replied message or story; pass null if none.
    • options

      public TdApi.MessageSendOptions options
      Options to be used to send the message; pass null to use default options.
    • replyMarkup

      public TdApi.ReplyMarkup replyMarkup
      Markup for replying to the message; pass null if none; for bots only.
    • inputMessageContent

      public TdApi.InputMessageContent inputMessageContent
      The content of the message to be sent.
    • CONSTRUCTOR

      public static final int CONSTRUCTOR
      Identifier uniquely determining type of the object.
      See Also:
  • Constructor Details

    • SendMessage

      public SendMessage()
      Sends a message. Returns the sent message.

      Returns Message

    • SendMessage

      public SendMessage(long chatId, long messageThreadId, TdApi.MessageReplyTo replyTo, TdApi.MessageSendOptions options, TdApi.ReplyMarkup replyMarkup, TdApi.InputMessageContent inputMessageContent)
      Sends a message. Returns the sent message.

      Returns Message

      Parameters:
      chatId - Target chat.
      messageThreadId - If not 0, a message thread identifier in which the message will be sent.
      replyTo - Identifier of the replied message or story; pass null if none.
      options - Options to be used to send the message; pass null to use default options.
      replyMarkup - Markup for replying to the message; pass null if none; for bots only.
      inputMessageContent - The content of the message to be sent.

      Returns Message

    • SendMessage

      public SendMessage(DataInput input) throws IOException
      Sends a message. Returns the sent message.

      Returns Message

      Parameters:
      input - Serialized input
      Throws:
      IOException - the deserialization failed
  • Method Details

    • getConstructor

      public int getConstructor()
      Description copied from class: TdApi.Object
      Returns an identifier uniquely determining type of the object.
      Specified by:
      getConstructor in class TdApi.Object
      Returns:
      this.CONSTRUCTOR
    • serialize

      public void serialize(DataOutput output) throws IOException
      Serialize the TDLib class
      Specified by:
      serialize in class TdApi.Object
      Parameters:
      output - output data stream
      Throws:
      IOException - the serialization failed
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object