Ошибка при создании Телеграм-бота: "Could not find or load main class"
Помогите, пожалуйста, не могу въехать.
Пыталась написать телеграм-бота, IntelliJ IDEA.
Выдаёт:
Error: Could not find or load main class Bot Caused by: java.lang.ClassNotFoundException: Bot
Не понимаю, что можно сделать, хэлп!((
public class Bot extends TelegramLongPollingBot {
public static void main(String[] args) {
ApiContextInitializer.init();
TelegramBotsApi telegramBotsApi = new TelegramBotsApi();
try {
telegramBotsApi.registerBot(new Bot());
} catch (TelegramApiRequestException e) {
e.printStackTrace();
}
}
@Override
public void onUpdateReceived(Update update) {
SendMessage response = new SendMessage();
response.setText("Привет!");
try {
execute(response);
} catch (TelegramApiException e) {
e.printStackTrace();
}