Completed
Push — master ( 0cb834...ce1742 )
by Camilo
04:29
created

ChosenInlineResult   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 27
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1
Metric Value
wmc 1
lcom 0
cbo 1
dl 0
loc 27
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A mapSubObjects() 0 6 1
1
<?php
2
3
declare(strict_types = 1);
4
5
namespace unreal4u\Telegram\Types;
6
7
use unreal4u\Abstracts\TelegramTypes;
8
9
/**
10
 * This object represents a result of an inline query that was chosen by the user and sent to their chat partner.
11
 *
12
 * Objects defined as-is january 2016
13
 *
14
 * @see https://core.telegram.org/bots/api#choseninlineresult
15
 */
16
class ChosenInlineResult extends TelegramTypes
17
{
18
    /**
19
     * The unique identifier for the result that was chosen
20
     * @var string
21
     */
22
    public $result_id = '';
23
24
    /**
25
     * The user that chose the result
26
     * @var User
27
     */
28
    public $from = null;
29
30
    /**
31
     * Text of the query
32
     * @var string
33
     */
34
    public $query = '';
35
36
    protected function mapSubObjects(): array
37
    {
38
        return [
39
            'from' => 'User',
40
        ];
41
    }
42
}
43