Module tdlight.api

Class TdApi.GetChatSparseMessagePositions

Enclosing class:
TdApi

public static final class TdApi.GetChatSparseMessagePositions extends TdApi.Function<TdApi.MessagePositions>
Returns sparse positions of messages of the specified type in the chat to be used for shared media scroll implementation. Returns the results in reverse chronological order (i.e., in order of decreasing messageId). Cannot be used in secret chats or with searchMessagesFilterFailedToSend filter without an enabled message database.

Returns MessagePositions

  • Field Details

    • chatId

      public long chatId
      Identifier of the chat in which to return information about message positions.
    • filter

      Filter for message content. Filters searchMessagesFilterEmpty, searchMessagesFilterMention, searchMessagesFilterUnreadMention, and searchMessagesFilterUnreadReaction are unsupported in this function.
    • fromMessageId

      public long fromMessageId
      The message identifier from which to return information about message positions.
    • limit

      public int limit
      The expected number of message positions to be returned; 50-2000. A smaller number of positions can be returned, if there are not enough appropriate messages.
    • CONSTRUCTOR

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

    • GetChatSparseMessagePositions

      public GetChatSparseMessagePositions()
      Returns sparse positions of messages of the specified type in the chat to be used for shared media scroll implementation. Returns the results in reverse chronological order (i.e., in order of decreasing messageId). Cannot be used in secret chats or with searchMessagesFilterFailedToSend filter without an enabled message database.

      Returns MessagePositions

    • GetChatSparseMessagePositions

      public GetChatSparseMessagePositions(long chatId, TdApi.SearchMessagesFilter filter, long fromMessageId, int limit)
      Returns sparse positions of messages of the specified type in the chat to be used for shared media scroll implementation. Returns the results in reverse chronological order (i.e., in order of decreasing messageId). Cannot be used in secret chats or with searchMessagesFilterFailedToSend filter without an enabled message database.

      Returns MessagePositions

      Parameters:
      chatId - Identifier of the chat in which to return information about message positions.
      filter - Filter for message content. Filters searchMessagesFilterEmpty, searchMessagesFilterMention, searchMessagesFilterUnreadMention, and searchMessagesFilterUnreadReaction are unsupported in this function.
      fromMessageId - The message identifier from which to return information about message positions.
      limit - The expected number of message positions to be returned; 50-2000. A smaller number of positions can be returned, if there are not enough appropriate messages.

      Returns MessagePositions

    • GetChatSparseMessagePositions

      public GetChatSparseMessagePositions(DataInput input) throws IOException
      Returns sparse positions of messages of the specified type in the chat to be used for shared media scroll implementation. Returns the results in reverse chronological order (i.e., in order of decreasing messageId). Cannot be used in secret chats or with searchMessagesFilterFailedToSend filter without an enabled message database.

      Returns MessagePositions

      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