Showing 6 of 6 total issues

Missing class import via use statement (line '175', column '30').
Open

            $reflector = new \ReflectionClass($callable);
Severity: Minor
Found in src/Di/Factory/FactoryHelperTrait.php by phpmd

MissingImport

Since: 2.7.0

Importing all external classes in a file through use statements makes them clearly visible.

Example

function make() {
    return new \stdClass();
}

Source http://phpmd.org/rules/cleancode.html#MissingImport

Missing class import via use statement (line '180', column '27').
Open

            $method = new \ReflectionFunction($callable);
Severity: Minor
Found in src/Di/Factory/FactoryHelperTrait.php by phpmd

MissingImport

Since: 2.7.0

Importing all external classes in a file through use statements makes them clearly visible.

Example

function make() {
    return new \stdClass();
}

Source http://phpmd.org/rules/cleancode.html#MissingImport

Missing class import via use statement (line '170', column '30').
Open

            $reflector = new \ReflectionClass($callable[0]);
Severity: Minor
Found in src/Di/Factory/FactoryHelperTrait.php by phpmd

MissingImport

Since: 2.7.0

Importing all external classes in a file through use statements makes them clearly visible.

Example

function make() {
    return new \stdClass();
}

Source http://phpmd.org/rules/cleancode.html#MissingImport

Missing class import via use statement (line '75', column '26').
Open

        $reflector = new \ReflectionClass($class);
Severity: Minor
Found in src/Di/Factory/FactoryHelperTrait.php by phpmd

MissingImport

Since: 2.7.0

Importing all external classes in a file through use statements makes them clearly visible.

Example

function make() {
    return new \stdClass();
}

Source http://phpmd.org/rules/cleancode.html#MissingImport

The 'getObjectMethod()' method which returns a boolean should be named 'is...()' or 'has...()'
Open

    protected function getObjectMethod($object, $method)/*# : bool */
    {
        if (is_string($method) && method_exists($object, $method)) {
            return [$object, $method];
        } elseif (is_callable($method)) {
Severity: Minor
Found in src/Di/Factory/FactoryHelperTrait.php by phpmd

BooleanGetMethodName

Since: 0.2

Looks for methods named 'getX()' with 'boolean' as the return type. The convention is to name these methods 'isX()' or 'hasX()'.

Example

class Foo {
    /**
     * @return boolean
     */
    public function getFoo() {} // bad
    /**
     * @return bool
     */
    public function isFoo(); // ok
    /**
     * @return boolean
     */
    public function getFoo($bar); // ok, unless checkParameterizedMethods=true
}

Source https://phpmd.org/rules/naming.html#booleangetmethodname

The method __callstatic is not named in camelCase.
Open

    public static function __callstatic(/*# string */ $method, array $params)
    {
        if (static::$container) {
            // append scope if provided
            if (!isset($params[0])) {
Severity: Minor
Found in src/Di/Service.php by phpmd

CamelCaseMethodName

Since: 0.2

It is considered best practice to use the camelCase notation to name methods.

Example

class ClassName {
    public function get_name() {
    }
}

Source

Severity
Category
Status
Source
Language