chamilo/chamilo-lms

View on GitHub
src/CoreBundle/Entity/GradeModel.php

Summary

Maintainability
A
0 mins
Test Coverage

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Column(name: 'id', type: 'integer')]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Column(name: 'default_external_eval', type: 'boolean', nullable: true)]

Add a single space around assignment operators
Open

declare(strict_types=1);

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

#[ORM\Entity]

Missing function doc comment
Open

    public function setDefaultLowestEvalExclude(bool $defaultLowestEvalExclude): self

Missing function doc comment
Open

    public function setDefaultExternalEval(bool $defaultExternalEval): self

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\GeneratedValue]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Column(name: 'description', type: 'text', nullable: true)]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

#[ORM\Table(name: 'grade_model')]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Column(name: 'default_lowest_eval_exclude', type: 'boolean', nullable: true)]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Column(name: 'default_external_eval_prefix', type: 'string', length: 140, nullable: true)]

Missing function doc comment
Open

    public function setTitle(string $title): self

Missing function doc comment
Open

    public function setDefaultExternalEvalPrefix(string $defaultExternalEvalPrefix): self

Missing function doc comment
Open

    public function setDescription(string $description): self

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Id]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Column(name: 'title', type: 'string', length: 255, nullable: false)]

You must use "/**" style comments for a class comment
Open

class GradeModel

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

    public function getDefaultExternalEval()
    {
        return $this->defaultExternalEval;
    }
Severity: Minor
Found in src/CoreBundle/Entity/GradeModel.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 'getDefaultLowestEvalExclude()' method which returns a boolean should be named 'is...()' or 'has...()'
Open

    public function getDefaultLowestEvalExclude()
    {
        return $this->defaultLowestEvalExclude;
    }
Severity: Minor
Found in src/CoreBundle/Entity/GradeModel.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

There are no issues that match your filters.

Category
Status