Moved Objects

This commit is contained in:
netkas 2024-10-02 00:18:12 -04:00
parent 848a2a78e3
commit 6c67e97a4b
167 changed files with 368 additions and 373 deletions

View file

@ -0,0 +1,51 @@
<?php
/** @noinspection PhpUnused */
/** @noinspection PhpMissingFieldTypeInspection */
namespace TgBotLib\Objects;
use TgBotLib\Interfaces\ObjectTypeInterface;
class SentWebAppMessage implements ObjectTypeInterface
{
/**
* @var string|null
*/
private $inline_message_id;
/**
* @return string|null
*/
public function getInlineMessageId(): ?string
{
return $this->inline_message_id;
}
/**
* Returns an array representation of the object
*
* @return null[]|string[]
*/
public function toArray(): array
{
return [
'inline_message_id' => $this->inline_message_id,
];
}
/**
* Constructs object from an array representation
*
* @param array $data
* @return SentWebAppMessage
*/
public static function fromArray(array $data): SentWebAppMessage
{
$object = new self();
$object->inline_message_id = $data['inline_message_id'] ?? null;
return $object;
}
}