Class ApprovePostCallbackQueryCommand

java.lang.Object
io.github.yvasyliev.forwarder.telegram.bot.service.command.ApprovePostCallbackQueryCommand
All Implemented Interfaces:
CallbackQueryCommand<CommandCallbackData>, PostControlsCallbackQueryCommand

@Service("/approvepost") public class ApprovePostCallbackQueryCommand extends Object implements PostControlsCallbackQueryCommand
Approves a post by saving its message IDs.
  • Constructor Details

    • ApprovePostCallbackQueryCommand

      public ApprovePostCallbackQueryCommand(ApprovedPostService postService)
  • Method Details

    • execute

      public void execute(org.telegram.telegrambots.meta.api.objects.CallbackQuery callbackQuery, CommandCallbackData callbackData)
      Description copied from interface: CallbackQueryCommand
      Executes the command with the provided callback query and data.
      Specified by:
      execute in interface CallbackQueryCommand<CommandCallbackData>
      Parameters:
      callbackQuery - the callback query containing the command
      callbackData - the data associated with the command