Completed
Push — master ( c692a8...3329a0 )
by Irfaq
12:30 queued 10:17
created

CallbackQuery::relations()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 7
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 7
ccs 0
cts 4
cp 0
rs 9.4285
cc 1
eloc 4
nc 1
nop 0
crap 2
1
<?php
2
3
namespace Telegram\Bot\Objects;
4
5
/**
6
 * Class CallbackQuery.
7
 *
8
 * @method int              getId()               Unique message identifier.
9
 * @method User             getFrom()             Sender.
10
 * @method Message          getMessage()          (Optional). Message with the callback button that originated the query. Note that message content and message date will not be available if the message is too old.
11
 * @method string           getInlineMessageId()  (Optional). Identifier of the message sent via the bot in inline mode, that originated the query.
12
 * @method string           getData()             (Optional). Data associated with the callback button. Be aware that a bad client can send arbitrary data in this field.
13
 */
14
class CallbackQuery extends BaseObject
15
{
16
    /**
17
     * {@inheritdoc}
18
     */
19
    public function relations()
20
    {
21
        return [
22
            'from'    => User::class,
23
            'message' => Message::class,
24
        ];
25
    }
26
}
27