Completed
Push — next ( 3fc9f0...5d2fc6 )
by Jonathan
9s
created

TestClass::arrayHint()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 1
nc 1
nop 1
dl 0
loc 3
rs 10
c 0
b 0
f 0
1
<?php
2
3
namespace Kint\Test\Fixtures;
4
5
class TestClass
6
{
7
    const DUMP_FILE = __FILE__;
8
    const DUMP_LINE = 60;
9
10
    public $pub;
11
    protected $pro;
12
    private $pri;
13
14
    public static $pubstat;
15
    protected static $prostat;
16
    private static $pristat;
0 ignored issues
show
Unused Code introduced by
The property $pristat is not used and could be removed.

This check marks private properties in classes that are never used. Those properties can be removed.

Loading history...
17
18
    /**
19
     * This is a constructor for a TestClass with the first
20
     * line of the docstring split into two different lines.
21
     *
22
     * And here's some more information about it
23
     */
24
    public function __construct()
25
    {
26
        $this->pub = array('pub');
27
        $this->pro = array('pro');
28
        $this->pri = array('pri');
29
    }
30
31
    private static function staticMethod()
0 ignored issues
show
Unused Code introduced by
This method is not used, and could be removed.
Loading history...
32
    {
33
    }
34
35
    final public function finalMethod()
36
    {
37
    }
38
39
    /**
40
     * @param array $x
41
     */
42
    private function arrayHint(array $x)
0 ignored issues
show
Unused Code introduced by
This method is not used, and could be removed.
Loading history...
Unused Code introduced by
The parameter $x is not used and could be removed.

This check looks from parameters that have been defined for a function or method, but which are not used in the method body.

Loading history...
Comprehensibility introduced by
Avoid variables with short names like $x. Configured minimum length is 3.

Short variable names may make your code harder to understand. Variable names should be self-descriptive. This check looks for variable names who are shorter than a configured minimum.

Loading history...
43
    {
44
    }
45
46
    private function classHint(TestClass $x)
0 ignored issues
show
Unused Code introduced by
This method is not used, and could be removed.
Loading history...
Unused Code introduced by
The parameter $x is not used and could be removed.

This check looks from parameters that have been defined for a function or method, but which are not used in the method body.

Loading history...
Comprehensibility introduced by
Avoid variables with short names like $x. Configured minimum length is 3.

Short variable names may make your code harder to understand. Variable names should be self-descriptive. This check looks for variable names who are shorter than a configured minimum.

Loading history...
47
    {
48
    }
49
50
    private function ref(&$x)
0 ignored issues
show
Unused Code introduced by
This method is not used, and could be removed.
Loading history...
Unused Code introduced by
The parameter $x is not used and could be removed.

This check looks from parameters that have been defined for a function or method, but which are not used in the method body.

Loading history...
Comprehensibility introduced by
Avoid variables with short names like $x. Configured minimum length is 3.

Short variable names may make your code harder to understand. Variable names should be self-descriptive. This check looks for variable names who are shorter than a configured minimum.

Loading history...
51
    {
52
    }
53
54
    private function defaultMethod($x = 1234)
0 ignored issues
show
Unused Code introduced by
This method is not used, and could be removed.
Loading history...
Unused Code introduced by
The parameter $x is not used and could be removed.

This check looks from parameters that have been defined for a function or method, but which are not used in the method body.

Loading history...
Comprehensibility introduced by
Avoid variables with short names like $x. Configured minimum length is 3.

Short variable names may make your code harder to understand. Variable names should be self-descriptive. This check looks for variable names who are shorter than a configured minimum.

Loading history...
55
    {
56
    }
57
58
    final protected static function &mix(array &$x, TestClass $y = null, $z = array(1, 2, 3), $_ = 'string')
0 ignored issues
show
Coding Style introduced by
$_ does not seem to conform to the naming convention (^[a-z][a-zA-Z0-9]*$).

This check examines a number of code elements and verifies that they conform to the given naming conventions.

You can set conventions for local variables, abstract classes, utility classes, constant, properties, methods, parameters, interfaces, classes, exceptions and special methods.

Loading history...
Unused Code introduced by
The parameter $_ is not used and could be removed.

This check looks from parameters that have been defined for a function or method, but which are not used in the method body.

Loading history...
Comprehensibility introduced by
Avoid variables with short names like $x. Configured minimum length is 3.

Short variable names may make your code harder to understand. Variable names should be self-descriptive. This check looks for variable names who are shorter than a configured minimum.

Loading history...
Comprehensibility introduced by
Avoid variables with short names like $y. Configured minimum length is 3.

Short variable names may make your code harder to understand. Variable names should be self-descriptive. This check looks for variable names who are shorter than a configured minimum.

Loading history...
Comprehensibility introduced by
Avoid variables with short names like $z. Configured minimum length is 3.

Short variable names may make your code harder to understand. Variable names should be self-descriptive. This check looks for variable names who are shorter than a configured minimum.

Loading history...
Comprehensibility introduced by
Avoid variables with short names like $_. Configured minimum length is 3.

Short variable names may make your code harder to understand. Variable names should be self-descriptive. This check looks for variable names who are shorter than a configured minimum.

Loading history...
Coding Style Naming introduced by
The parameter $_ is not named in camelCase.

This check marks parameter names that have not been written in camelCase.

In camelCase names are written without any punctuation, the start of each new word being marked by a capital letter. Thus the name database connection string becomes databaseConnectionString.

Loading history...
59
    {
60
        \Kint::dump($x, $y, $z);
61
        +!\Kint::dump();
62
        ~\d($x);
63
    }
64
65
    public function __clone()
66
    {
67
        return new self();
68
    }
69
70
    public function __invoke($x)
0 ignored issues
show
Comprehensibility introduced by
Avoid variables with short names like $x. Configured minimum length is 3.

Short variable names may make your code harder to understand. Variable names should be self-descriptive. This check looks for variable names who are shorter than a configured minimum.

Loading history...
71
    {
72
        return 'woot';
73
    }
74
75
    public function __ToStRiNg()
76
    {
77
        return 'I am totally a string';
78
    }
79
80
    public function __get($param)
81
    {
82
        return 'Ouch!';
83
    }
84
}
85