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.

SimpleDirective::isSimple()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
crap 1
1
<?php
2
3
/**
4
 * This file is part of WebHelper Parser.
5
 *
6
 * (c) James <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace WebHelper\Parser\Directive;
13
14
use WebHelper\Parser\Server\ServerInterface;
15
16
/**
17
 * Describes a simple directive instance.
18
 *
19
 * a SimpleDirective is a simple key/value information.
20
 *
21
 * @author James <[email protected]>
22
 */
23
class SimpleDirective extends Directive implements DirectiveInterface
24
{
25
    /**
26
     * Confirms if the directive contains a specified directive.
27
     *
28
     * @param string $name the directive for which to check existence
29
     *
30
     * @return bool true if the sub-directive exists, false otherwise
31
     */
32 1
    public function hasDirective($name)
33
    {
34 1
        return false;
35
    }
36
37
    /**
38
     * Confirms if the directive is simple.
39
     *
40
     * Simple directive cannot have sub directive
41
     *
42
     * @return bool true if the directive is simple, false otherwise
43
     */
44 1
    public function isSimple()
45
    {
46 1
        return true;
47
    }
48
49
    /**
50
     * Dumps the directive respecting a server syntax.
51
     *
52
     * @param ServerInterface $server a server instance
53
     * @param int             $spaces the indentation spaces
54
     *
55
     * @return string the dumped directive
56
     */
57 1
    public function dump(ServerInterface $server, $spaces = 0)
58
    {
59 1
        return $this->dumpSimple($server, $spaces);
60
    }
61
}
62