Th::__construct()   A
last analyzed

Complexity

Conditions 2
Paths 2

Size

Total Lines 5
Code Lines 3

Duplication

Lines 5
Ratio 100 %

Importance

Changes 2
Bugs 1 Features 0
Metric Value
c 2
b 1
f 0
dl 5
loc 5
rs 9.4285
cc 2
eloc 3
nc 2
nop 1
1
<?php
2
3
namespace hemio\html;
4
5
/**
6
 * The <code>th</code> element represents a header cell in a table.
7
 *
8
 * @since version 1.0
9
 * @url http://www.w3.org/TR/html5/tabular-data.html#the-th-element
10
 */
11 View Code Duplication
class Th extends Abstract_\ElementContent
0 ignored issues
show
Duplication introduced by
This class seems to be duplicated in your project.

Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.

You can also find more detailed suggestions in the “Code” section of your repository.

Loading history...
12
{
13
14
    use Trait_\DefaultElementContent;
15
16
    public static function tagName()
17
    {
18
        return 'th';
19
    }
20
21
    function __construct(Interface_\HtmlCode $objContent = null)
0 ignored issues
show
Best Practice introduced by
It is generally recommended to explicitly declare the visibility for methods.

Adding explicit visibility (private, protected, or public) is generally recommend to communicate to other developers how, and from where this method is intended to be used.

Loading history...
22
    {
23
        if ($objContent !== null)
24
            $this->addChild($objContent);
25
    }
26
}
27