InlineQueryResultGame   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 11
Duplicated Lines 0 %

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
eloc 3
dl 0
loc 11
ccs 0
cts 3
cp 0
rs 10
c 0
b 0
f 0
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
1
<?php
2
3
/**
4
 * This file is part of the TelegramBot package.
5
 *
6
 * (c) Avtandil Kikabidze aka LONGMAN <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace Longman\TelegramBot\Entities\InlineQuery;
13
14
use Longman\TelegramBot\Entities\InlineKeyboard;
15
16
/**
17
 * Class InlineQueryResultGame
18
 *
19
 * @link https://core.telegram.org/bots/api#inlinequeryresultgame
20
 *
21
 * <code>
22
 * $data = [
23
 *   'id'              => '',
24
 *   'game_short_name' => '',
25
 *   'reply_markup'    => <InlineKeyboard>,
26
 * ];
27
 * </code>
28
 *
29
 * @method string         getType()          Type of the result, must be game
30
 * @method string         getId()            Unique identifier for this result, 1-64 bytes
31
 * @method string         getGameShortName() Short name of the game
32
 * @method InlineKeyboard getReplyMarkup()   Optional. Inline keyboard attached to the message
33
 *
34
 * @method $this setId(string $id)                            Unique identifier for this result, 1-64 bytes
35
 * @method $this setGameShortName(string $game_short_name)    Short name of the game
36
 * @method $this setReplyMarkup(InlineKeyboard $reply_markup) Optional. Inline keyboard attached to the message
37
 */
38
class InlineQueryResultGame extends InlineEntity implements InlineQueryResult
39
{
40
    /**
41
     * InlineQueryResultGame constructor
42
     *
43
     * @param array $data
44
     */
45
    public function __construct(array $data = [])
46
    {
47
        $data['type'] = 'game';
48
        parent::__construct($data);
49
    }
50
}
51