Move UpdateEvent to Events and remove unused import

This commit is contained in:
netkas 2024-11-06 15:02:43 -05:00
parent 24fe2f2b91
commit 646c77c4ba
27 changed files with 4 additions and 28 deletions

View file

@ -1,42 +0,0 @@
<?php
namespace TgBotLib\Abstracts;
use TgBotLib\Bot;
use TgBotLib\Enums\EventType;
use TgBotLib\Exceptions\TelegramException;
use TgBotLib\Objects\Update;
abstract class UpdateEvent
{
protected Update $update;
/**
* Constructor for the class.
*
* @param Update $update The update instance to be used.
* @return void
*/
public function __construct(Update $update)
{
$this->update = $update;
}
/**
* Retrieves the event type.
* @return EventType The event type of the current instance.
*/
public static function getEventType(): EventType
{
return EventType::UPDATE_EVENT;
}
/**
* Abstract method to handle the bot instance.
*
* @param Bot $bot The bot instance to be handled.
* @return void
* @throws TelegramException
*/
public abstract function handle(Bot $bot): void;
}