Radio   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 8
c 1
b 0
f 0
dl 0
loc 16
rs 10
wmc 2

1 Method

Rating   Name   Duplication   Size   Complexity  
A render() 0 8 2
1
<?php
2
3
namespace GeminiLabs\Castor\Forms\Fields;
4
5
class Radio extends Base
6
{
7
    protected $multi = true;
8
    protected $element = 'input';
9
10
    /**
11
     * @return string
12
     */
13
    public function render($default = null)
14
    {
15
        $inline = $this->args['inline'] ? ' class="inline"' : '';
16
17
        return sprintf('<ul%s>%s</ul>%s',
18
            $inline,
19
            $this->implodeOptions('multi_input', $default),
20
            $this->generateDescription()
21
        );
22
    }
23
}
24