Passed
Push — api-5.4 ( 922510 )
by
unknown
07:11
created

ChatJoinRequest::subEntities()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 6
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 4
nc 1
nop 0
dl 0
loc 6
rs 10
c 1
b 0
f 0
1
<?php
2
3
namespace Longman\TelegramBot\Entities;
4
5
/**
6
 * Class ChatJoinRequest
7
 *
8
 * Represents a join request sent to a chat.
9
 *
10
 * @link https://core.telegram.org/bots/api#chatjoinrequest
11
 *
12
 * @method Chat           getChat()       Chat to which the request was sent
13
 * @method User           getUser()       User that sent the join request
14
 * @method int            getDate()       Date the request was sent in Unix time
15
 * @method string         getBio()        Optional. Bio of the user.
16
 * @method ChatInviteLink getInviteLink() Optional. Chat invite link that was used by the user to send the join request
17
 */
18
class ChatJoinRequest extends Entity
19
{
20
21
    protected function subEntities(): array
22
    {
23
        return [
24
            'chat'        => Chat::class,
25
            'from'        => User::class,
26
            'invite_link' => ChatInviteLink::class,
27
        ];
28
    }
29
30
}
31