All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.telegram.telegrambots.longpolling.starter.AfterBotRegistration Maven / Gradle / Ivy

The newest version!
package org.telegram.telegrambots.longpolling.starter;

import org.telegram.telegrambots.longpolling.BotSession;
import org.telegram.telegrambots.longpolling.TelegramBotsLongPollingApplication;
import org.telegram.telegrambots.longpolling.interfaces.LongPollingUpdateConsumer;
import org.telegram.telegrambots.longpolling.util.LongPollingSingleThreadUpdateConsumer;

import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

/**
 * Indicated that the Method of a Class extending {@link SpringLongPollingBot} will be called after the bot was registered
 * If the Method has a single Parameter of type {@link BotSession}, the method get passed the bot session the bot was registered with
 * 

*

The bot session passed is the ones returned by {@link TelegramBotsLongPollingApplication#registerBot(String, LongPollingUpdateConsumer)}

*/ @Target(ElementType.METHOD) @Retention(RetentionPolicy.RUNTIME) public @interface AfterBotRegistration {}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy