Passed
Push — master ( 26433b...596cc9 )
by Armando
16:00 queued 05:59
created

MessageOriginChannel::subEntities()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 2
c 1
b 0
f 0
nc 1
nop 0
dl 0
loc 4
rs 10
1
<?php
2
3
namespace Longman\TelegramBot\Entities\MessageOrigin;
4
5
use Longman\TelegramBot\Entities\Chat;
6
use Longman\TelegramBot\Entities\Entity;
7
8
/**
9
 * The message was originally sent to a channel chat.
10
 *
11
 * @link https://core.telegram.org/bots/api#messageoriginchannel
12
 *
13
 * @method string getType()            Type of the message origin, always “channel”
14
 * @method int    getDate()            Date the message was sent originally in Unix time
15
 * @method Chat   getChat()            Channel chat to which the message was originally sent
16
 * @method int    getMessageId()       Unique message identifier inside the chat
17
 * @method string getAuthorSignature() Optional. Signature of the original post author
18
 */
19
class MessageOriginChannel extends Entity implements MessageOrigin
20
{
21
    protected function subEntities(): array
22
    {
23
        return [
24
            'chat' => Chat::class,
25
        ];
26
    }
27
}
28