ChatJoinRequest   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 12
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 1
eloc 5
c 1
b 0
f 0
dl 0
loc 12
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A subEntities() 0 6 1
1
<?php
2
3
namespace TelegramBot\Entities;
4
5
use TelegramBot\Entity;
6
7
/**
8
 * Class ChatJoinRequest
9
 *
10
 * Represents a join request sent to a chat.
11
 *
12
 * @link https://core.telegram.org/bots/api#chatjoinrequest
13
 *
14
 * @method Chat           getChat()        Chat to which the request was sent
15
 * @method User           getFrom()        User that sent the join request
16
 * @method int            getDate()        Date the request was sent in Unix time
17
 * @method string         getBio()            Optional. Bio of the user.
18
 * @method ChatInviteLink getInviteLink()    Optional. Chat invite link that was used by the user to send the join request
19
 */
20
class ChatJoinRequest extends Entity
21
{
22
23
    /**
24
     * {@inheritdoc}
25
     */
26
    protected function subEntities(): array
27
    {
28
        return [
29
            'chat' => Chat::class,
30
            'from' => User::class,
31
            'invite_link' => ChatInviteLink::class,
32
        ];
33
    }
34
35
}
36