Class TelegramUpdateConsumer

java.lang.Object
io.github.yvasyliev.telegramforwarderbot.service.TelegramUpdateConsumer
All Implemented Interfaces:
org.telegram.telegrambots.longpolling.interfaces.LongPollingUpdateConsumer

@Service public class TelegramUpdateConsumer extends Object implements org.telegram.telegrambots.longpolling.interfaces.LongPollingUpdateConsumer
Service for consuming updates from Telegram and handling them accordingly. It processes incoming updates, such as messages and callback queries, and delegates the handling to the appropriate event handlers.
  • Constructor Details

    • TelegramUpdateConsumer

      public TelegramUpdateConsumer()
  • Method Details

    • consume

      @Async public void consume(List<org.telegram.telegrambots.meta.api.objects.Update> updates)
      Specified by:
      consume in interface org.telegram.telegrambots.longpolling.interfaces.LongPollingUpdateConsumer