Completed
Push — master ( a1a3b2...ba72b8 )
by Derek Stephen
07:25
created

Submit::__construct()   A

Complexity

Conditions 2
Paths 2

Size

Total Lines 6
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 5
CRAP Score 2

Importance

Changes 0
Metric Value
dl 0
loc 6
ccs 5
cts 5
cp 1
rs 9.4285
c 0
b 0
f 0
cc 2
eloc 4
nc 2
nop 2
crap 2
1
<?php
2
/**
3
 * User: delboy1978uk
4
 * Date: 19/11/2016
5
 * Time: 21:37
6
 */
7
8
namespace Del\Form\Field;
9
10
class Submit extends FieldAbstract
11
{
12
    /**
13
     * @return string
14
     */
15 1
    public function getTag()
16
    {
17 1
        return 'input';
18
    }
19
20
    /**
21
     * @return string
22
     */
23 1
    public function getTagType()
24
    {
25 1
        return 'submit';
26
    }
27
28 1
    public function __construct($name, $value = null)
29
    {
30 1
        $value = is_null($value) ? $name : $value;
31 1
        parent::__construct($name, $value);
32 1
        $this->setClass('btn btn-primary');
33
    }
34
}