Completed
Push — master ( aef7f8...916348 )
by WEBEWEB
01:35
created

DataTablesMapping::getColumn()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 3
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
1
<?php
2
3
/*
4
 * This file is part of the jquery-datatables-bundle package.
5
 *
6
 * (c) 2018 WEBEWEB
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 WBW\Bundle\JQuery\DataTablesBundle\Model;
13
14
use WBW\Bundle\JQuery\DataTablesBundle\API\DataTablesColumnInterface;
15
use WBW\Bundle\JQuery\DataTablesBundle\API\DataTablesMappingInterface;
16
17
/**
18
 * DataTables mapping.
19
 *
20
 * @author webeweb <https://github.com/webeweb/>
21
 * @package WBW\Bundle\JQuery\DataTablesBundle\Model
22
 */
23
class DataTablesMapping implements DataTablesMappingInterface {
24
25
    /**
26
     * Column.
27
     *
28
     * @var string|null
29
     */
30
    private $column;
31
32
    /**
33
     * Parent.
34
     *
35
     * @var DataTablesColumnInterface|null
36
     */
37
    private $parent;
38
39
    /**
40
     * Prefix.
41
     *
42
     * @var string|null
43
     */
44
    private $prefix;
45
46
    /**
47
     * Constructor.
48
     */
49
    public function __construct() {
50
        // NOTHING TO DO
51
    }
52
53
    /**
54
     * {@inheritDoc}
55
     */
56
    public function getColumn(): ?string {
57
        return $this->column;
58
    }
59
60
    /**
61
     * {@inheritDoc}
62
     */
63
    public function getParent(): ?DataTablesColumnInterface {
64
        return $this->parent;
65
    }
66
67
    /**
68
     * {@inheritDoc}
69
     */
70
    public function getPrefix(): ?string {
71
        return $this->prefix;
72
    }
73
74
    /**
75
     * {@inheritDoc}
76
     */
77
    public function setColumn(?string $column): DataTablesMappingInterface {
78
        $this->column = $column;
79
        return $this;
80
    }
81
82
    /**
83
     * Set the parent.
84
     *
85
     * @param DataTablesColumnInterface|null $parent The parent.
86
     * @return DataTablesMappingInterface Returns this mapping.
87
     */
88
    public function setParent(?DataTablesColumnInterface $parent): DataTablesMappingInterface {
89
        $this->parent = $parent;
90
        return $this;
91
    }
92
93
    /**
94
     * {@inheritDoc}
95
     */
96
    public function setPrefix(?string $prefix): DataTablesMappingInterface {
97
        $this->prefix = $prefix;
98
        return $this;
99
    }
100
}
101