Passed
Push — master ( 41990d...862f39 )
by Gabor
09:16 queued 04:24
created

AbstractTabindexElement   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 26
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 2
lcom 0
cbo 1
dl 0
loc 26
ccs 8
cts 8
cp 1
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 6 1
A __clone() 0 6 1
1
<?php
2
/**
3
 * WebHemi.
4
 *
5
 * PHP version 5.6
6
 *
7
 * @copyright 2012 - 2016 Gixx-web (http://www.gixx-web.com)
8
 * @license   https://opensource.org/licenses/MIT The MIT License (MIT)
9
 *
10
 * @link      http://www.gixx-web.com
11
 */
12
namespace WebHemi\Form\Element\Web;
13
14
/**
15
 * Class AbstractTabindexElement
16
 */
17
abstract class AbstractTabindexElement extends AbstractElement
18
{
19
    /**
20
     * SelectElement constructor.
21
     *
22
     * @param string $name
23
     * @param string $label
24
     * @param mixed  $value
25
     */
26 25
    public function __construct($name = '', $label = '', $value = null)
27
    {
28 25
        parent::__construct($name, $label, $value);
29
30 25
        $this->setTabIndex();
31 25
    }
32
33
    /**
34
     * Resets the object when cloning.
35
     */
36 3
    public function __clone()
37
    {
38 3
        parent::__clone();
39
40 3
        $this->setTabIndex();
41 3
    }
42
}
43