Interface MessageIdsCallbackDataMapper


public interface MessageIdsCallbackDataMapper
Mapper interface for converting between MessageIdsCommandCallbackDataDTO and MessageIdsTelegramCommandCallbackDataDTO. This interface uses MapStruct to generate the implementation at compile time.
  • Method Details

    • map

      Maps a MessageIdsCommandCallbackDataDTO to a MessageIdsTelegramCommandCallbackDataDTO.
      Parameters:
      callbackData - the source callback data
      Returns:
      the mapped Telegram command callback data
    • map

      Maps a MessageIdsTelegramCommandCallbackDataDTO to a MessageIdsCommandCallbackDataDTO.
      Parameters:
      callbackData - the source Telegram command callback data
      Returns:
      the mapped command callback data
    • getSize

      default int getSize(Collection<?> collection)
      Gets the size of a collection.
      Parameters:
      collection - the collection to get the size of
      Returns:
      the size of the collection
    • mapMessageIds

      default List<Integer> mapMessageIds(MessageIdsTelegramCommandCallbackDataDTO callbackData)
      Maps the message IDs from a MessageIdsTelegramCommandCallbackDataDTO to a list of integers. This method generates a list of integers starting from the first message ID and continuing for the specified number of messages.
      Parameters:
      callbackData - the source Telegram command callback data containing the first message ID and count
      Returns:
      a list of message IDs