Passed
Pull Request — master (#34)
by Marc
05:44
created

TableList::toArray()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 4
c 0
b 0
f 0
ccs 2
cts 2
cp 1
rs 10
cc 1
eloc 2
nc 1
nop 0
crap 1
1
<?php
2
declare(strict_types = 1);
3
4
namespace TBolier\RethinkQL\Query\Operation;
5
6
use TBolier\RethinkQL\Message\MessageInterface;
7
use TBolier\RethinkQL\Query\AbstractQuery;
8
use TBolier\RethinkQL\RethinkInterface;
9
use TBolier\RethinkQL\Types\Term\TermType;
10
11
class TableList extends AbstractQuery
12
{
13
    /**
14
     * @param RethinkInterface $rethink
15
     * @param MessageInterface $message
16
     */
17 12
    public function __construct(RethinkInterface $rethink, MessageInterface $message)
18
    {
19 12
        parent::__construct($rethink, $message);
20
21 12
        $this->rethink = $rethink;
22 12
        $this->message = $message;
23 12
    }
24
25
    /**
26
     * @inheritdoc
27
     */
28 12
    public function toArray(): array
29
    {
30
        return [
31 12
            TermType::TABLE_LIST,
32
        ];
33
    }
34
}
35