GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

Style   A
last analyzed

Complexity

Total Complexity 5

Size/Duplication

Total Lines 41
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 7
dl 0
loc 41
rs 10
c 0
b 0
f 0
wmc 5

3 Methods

Rating   Name   Duplication   Size   Complexity  
A __toString() 0 3 1
A offsetSet() 0 6 2
A import() 0 4 2
1
<?php
2
/**
3
 * This file is part of the O2System Framework package.
4
 *
5
 * For the full copyright and license information, please view the LICENSE
6
 * file that was distributed with this source code.
7
 *
8
 * @author         Steeve Andrian Salim
9
 * @copyright      Copyright (c) Steeve Andrian Salim
10
 */
11
12
// ------------------------------------------------------------------------
13
14
namespace O2System\Html\Dom;
15
16
// ------------------------------------------------------------------------
17
18
/**
19
 * Class Style
20
 *
21
 * @package O2System\HTML\DOM
22
 */
23
class Style extends \ArrayIterator
24
{
25
    /**
26
     * Style::import
27
     *
28
     * @param \O2System\Html\Dom\Style $style
29
     */
30
    public function import(Style $style)
31
    {
32
        foreach ($style->getArrayCopy() as $styleTextContent) {
33
            $this->append($styleTextContent);
34
        }
35
    }
36
37
    // ------------------------------------------------------------------------
38
39
    /**
40
     * Style::offsetSet
41
     *
42
     * @param string $offset
43
     * @param string $value
44
     */
45
    public function offsetSet($offset, $value)
46
    {
47
        $value = trim($value);
48
49
        if ( ! empty($value)) {
50
            parent::offsetSet($offset, $value);
51
        }
52
    }
53
54
    // ------------------------------------------------------------------------
55
56
    /**
57
     * Style::__toString
58
     *
59
     * @return string
60
     */
61
    public function __toString()
62
    {
63
        return PHP_EOL . implode(PHP_EOL, $this->getArrayCopy()) . PHP_EOL;
64
    }
65
}