XoopsModules25x/xoopsinfo

View on GitHub
phpsysinfo/includes/to/device/class.CpuDevice.inc.php

Summary

Maintainability
A
0 mins
Test Coverage

Avoid unused private fields such as '$_temp'.
Open

    private $_temp = null;

UnusedPrivateField

Since: 0.2

Detects when a private field is declared and/or assigned a value, but not used.

Example

class Something
{
    private static $FOO = 2; // Unused
    private $i = 5; // Unused
    private $j = 6;
    public function addOne()
    {
        return $this->j++;
    }
}

Source https://phpmd.org/rules/unusedcode.html#unusedprivatefield

Each class must be in a namespace of at least one level (a top-level vendor name)
Open

class CpuDevice

The property $_virt is not named in camelCase.
Open

class CpuDevice
{
    /**
     * model of the cpu
     *

CamelCasePropertyName

Since: 0.2

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

Example

class ClassName {
    protected $property_name;
}

Source

The property $_vendorid is not named in camelCase.
Open

class CpuDevice
{
    /**
     * model of the cpu
     *

CamelCasePropertyName

Since: 0.2

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

Example

class ClassName {
    protected $property_name;
}

Source

The property $_cpuSpeedMin is not named in camelCase.
Open

class CpuDevice
{
    /**
     * model of the cpu
     *

CamelCasePropertyName

Since: 0.2

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

Example

class ClassName {
    protected $property_name;
}

Source

The property $_model is not named in camelCase.
Open

class CpuDevice
{
    /**
     * model of the cpu
     *

CamelCasePropertyName

Since: 0.2

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

Example

class ClassName {
    protected $property_name;
}

Source

The property $_bogomips is not named in camelCase.
Open

class CpuDevice
{
    /**
     * model of the cpu
     *

CamelCasePropertyName

Since: 0.2

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

Example

class ClassName {
    protected $property_name;
}

Source

The property $_temp is not named in camelCase.
Open

class CpuDevice
{
    /**
     * model of the cpu
     *

CamelCasePropertyName

Since: 0.2

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

Example

class ClassName {
    protected $property_name;
}

Source

The property $_cache is not named in camelCase.
Open

class CpuDevice
{
    /**
     * model of the cpu
     *

CamelCasePropertyName

Since: 0.2

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

Example

class ClassName {
    protected $property_name;
}

Source

The property $_load is not named in camelCase.
Open

class CpuDevice
{
    /**
     * model of the cpu
     *

CamelCasePropertyName

Since: 0.2

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

Example

class ClassName {
    protected $property_name;
}

Source

The property $_cpuSpeedMax is not named in camelCase.
Open

class CpuDevice
{
    /**
     * model of the cpu
     *

CamelCasePropertyName

Since: 0.2

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

Example

class ClassName {
    protected $property_name;
}

Source

The property $_cpuSpeed is not named in camelCase.
Open

class CpuDevice
{
    /**
     * model of the cpu
     *

CamelCasePropertyName

Since: 0.2

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

Example

class ClassName {
    protected $property_name;
}

Source

The property $_busSpeed is not named in camelCase.
Open

class CpuDevice
{
    /**
     * model of the cpu
     *

CamelCasePropertyName

Since: 0.2

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

Example

class ClassName {
    protected $property_name;
}

Source

Property name "$_cache" should not be prefixed with an underscore to indicate visibility
Open

    private $_cache = null;

Property name "$_cpuSpeedMax" should not be prefixed with an underscore to indicate visibility
Open

    private $_cpuSpeedMax = 0;

Property name "$_busSpeed" should not be prefixed with an underscore to indicate visibility
Open

    private $_busSpeed = null;

Property name "$_virt" should not be prefixed with an underscore to indicate visibility
Open

    private $_virt = null;

Property name "$_cpuSpeed" should not be prefixed with an underscore to indicate visibility
Open

    private $_cpuSpeed = 0;

Property name "$_bogomips" should not be prefixed with an underscore to indicate visibility
Open

    private $_bogomips = null;

Property name "$_temp" should not be prefixed with an underscore to indicate visibility
Open

    private $_temp = null;

Property name "$_vendorid" should not be prefixed with an underscore to indicate visibility
Open

    private $_vendorid = null;

Property name "$_load" should not be prefixed with an underscore to indicate visibility
Open

    private $_load = null;

Property name "$_model" should not be prefixed with an underscore to indicate visibility
Open

    private $_model = "";

Property name "$_cpuSpeedMin" should not be prefixed with an underscore to indicate visibility
Open

    private $_cpuSpeedMin = 0;

Line exceeds 120 characters; contains 132 characters
Open

 * @license   http://opensource.org/licenses/gpl-2.0.php GNU General Public License version 2, or (at your option) any later version

Line exceeds 120 characters; contains 132 characters
Open

 * @license   http://opensource.org/licenses/gpl-2.0.php GNU General Public License version 2, or (at your option) any later version

There are no issues that match your filters.

Category
Status