Passed
Push — master ( f17b13...8bf1e0 )
by Radu
01:33
created

Request   A

Complexity

Total Complexity 6

Size/Duplication

Total Lines 47
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
wmc 6
eloc 18
dl 0
loc 47
rs 10
c 0
b 0
f 0

6 Methods

Rating   Name   Duplication   Size   Complexity  
A getDraw() 0 3 1
A __construct() 0 8 1
A getColumns() 0 3 1
A getLength() 0 3 1
A getStart() 0 3 1
A getOrder() 0 3 1
1
<?php
2
namespace WebServCo\Framework\DataTables;
3
4
use WebServCo\Framework\ArrayObject\Items;
5
6
class Request
7
{
8
    protected $draw;
9
10
    protected $columns;
11
12
    protected $order;
13
14
    protected $start;
15
16
    protected $length;
17
18
    protected $search;
19
20
    public function __construct($draw, Items $columns, Items $order, $start, $length, Search $search)
21
    {
22
        $this->draw = (int) $draw;
23
        $this->columns = $columns;
24
        $this->order = $order;
25
        $this->start = (int) $start;
26
        $this->length = (int) $length;
27
        $this->search = $search;
28
    }
29
30
    public function getColumns()
31
    {
32
        return $this->columns->getArrayObject();
33
    }
34
35
    public function getDraw()
36
    {
37
        return $this->draw;
38
    }
39
40
    public function getLength()
41
    {
42
        return $this->length;
43
    }
44
45
    public function getOrder()
46
    {
47
        return $this->order->getArrayObject();
48
    }
49
50
    public function getStart()
51
    {
52
        return $this->start;
53
    }
54
}
55