Completed
Push — master ( 8b59f7...62ee86 )
by Arjay
01:32
created

AutoFill   A

Complexity

Total Complexity 8

Size/Duplication

Total Lines 114
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 0

Importance

Changes 0
Metric Value
wmc 8
lcom 1
cbo 0
dl 0
loc 114
rs 10
c 0
b 0
f 0

8 Methods

Rating   Name   Duplication   Size   Complexity  
A languageAutoFill() 0 6 1
A languageAutoFillButton() 0 6 1
A languageAutoFillCancel() 0 6 1
A languageAutoFillFill() 0 6 1
A languageAutoFillFillHorizontal() 0 6 1
A languageAutoFillFillVertical() 0 6 1
A languageAutoFillIncrement() 0 6 1
A languageAutoFillInfo() 0 6 1
1
<?php
2
3
namespace Yajra\DataTables\Html\Options\Languages;
4
5
trait AutoFill
6
{
7
    /**
8
     * Set language autoFill option value.
9
     *
10
     * @param array $value
11
     * @return $this
12
     * @see https://datatables.net/reference/option/language.autoFill
13
     */
14
    public function languageAutoFill(array $value)
15
    {
16
        $this->attributes['language']['autoFill'] = $value;
0 ignored issues
show
Bug introduced by
The property attributes does not exist. Did you maybe forget to declare it?

In PHP it is possible to write to properties without declaring them. For example, the following is perfectly valid PHP code:

class MyClass { }

$x = new MyClass();
$x->foo = true;

Generally, it is a good practice to explictly declare properties to avoid accidental typos and provide IDE auto-completion:

class MyClass {
    public $foo;
}

$x = new MyClass();
$x->foo = true;
Loading history...
17
18
        return $this;
19
    }
20
21
    /**
22
     * Set language autoFill button option value.
23
     *
24
     * @param string $value
25
     * @return $this
26
     * @see https://datatables.net/reference/option/language.autoFill.button
27
     */
28
    public function languageAutoFillButton($value)
29
    {
30
        $this->attributes['language']['autoFill']['button'] = $value;
31
32
        return $this;
33
    }
34
35
    /**
36
     * Set language autoFill cancel option value.
37
     *
38
     * @param string $value
39
     * @return $this
40
     * @see https://datatables.net/reference/option/language.autoFill.cancel
41
     */
42
    public function languageAutoFillCancel($value)
43
    {
44
        $this->attributes['language']['autoFill']['cancel'] = $value;
45
46
        return $this;
47
    }
48
49
    /**
50
     * Set language autoFill fill option value.
51
     *
52
     * @param string $value
53
     * @return $this
54
     * @see https://datatables.net/reference/option/language.autoFill.fill
55
     */
56
    public function languageAutoFillFill($value)
57
    {
58
        $this->attributes['language']['autoFill']['fill'] = $value;
59
60
        return $this;
61
    }
62
63
    /**
64
     * Set language autoFill fillHorizontal option value.
65
     *
66
     * @param string $value
67
     * @return $this
68
     * @see https://datatables.net/reference/option/language.autoFill.fillHorizontal
69
     */
70
    public function languageAutoFillFillHorizontal($value)
71
    {
72
        $this->attributes['language']['autoFill']['fillHorizontal'] = $value;
73
74
        return $this;
75
    }
76
77
    /**
78
     * Set language autoFill fillVertical option value.
79
     *
80
     * @param string $value
81
     * @return $this
82
     * @see https://datatables.net/reference/option/language.autoFill.fillVertical
83
     */
84
    public function languageAutoFillFillVertical($value)
85
    {
86
        $this->attributes['language']['autoFill']['fillVertical'] = $value;
87
88
        return $this;
89
    }
90
91
    /**
92
     * Set language autoFill increment option value.
93
     *
94
     * @param string $value
95
     * @return $this
96
     * @see https://datatables.net/reference/option/language.autoFill.increment
97
     */
98
    public function languageAutoFillIncrement($value)
99
    {
100
        $this->attributes['language']['autoFill']['increment'] = $value;
101
102
        return $this;
103
    }
104
105
    /**
106
     * Set language autoFill info option value.
107
     *
108
     * @param string $value
109
     * @return $this
110
     * @see https://datatables.net/reference/option/language.autoFill.info
111
     */
112
    public function languageAutoFillInfo($value)
113
    {
114
        $this->attributes['language']['autoFill']['info'] = $value;
115
116
        return $this;
117
    }
118
}
119