PHP Classes
elePHPant
Icontem

File: PmdRules.xml

Recommend this page to a friend!
  Classes of Joseluis Laso  >  Simple PHP Memory Database  >  PmdRules.xml  >  Download  
File: PmdRules.xml
Role: Auxiliary data
Content type: text/plain
Description: Auxiliary data
Class: Simple PHP Memory Database
Manipulate databases stored in JSON format files
Author: By
Last change:
Date: 1 year ago
Size: 1,799 bytes
 

Contents

Class file image Download
<?xml version="1.0"?>

<!--
https://pear.php.net/manual/en/package.php.php-codesniffer.annotated-ruleset.php
-->

<ruleset name="My Ruleset">

    <description>My projects' common ruleset</description>

    <rule ref="rulesets/design.xml"/>
    <rule ref="rulesets/unusedcode.xml"/>
    <rule ref="rulesets/codesize.xml"/>

    <rule ref="rulesets/naming.xml">
        <exclude name="LongVariable"/>
        <exclude name="ShortVariable"/>
        <exclude name="ShortMethodName"/>
        <exclude name="BooleanGetMethodName"/>
    </rule>

    <rule ref="rulesets/naming.xml/ShortVariable"
          since="0.2"
          message="Avoid variables with short names like {0}. Minimum length is {1}."
          class="PHPMD\Rule\Naming\ShortVariable"
          externalInfoUrl="http://phpmd.org/rules/naming.html#shortvariable">
        <priority>3</priority>
        <properties>
            <property name="minimum" description="Minimum length for a variable, property or parameter name" value="3"/>
            <property name="exceptions" value="id,i,j,em"/>
        </properties>
    </rule>

    <rule ref="rulesets/naming.xml/LongVariable"
          since="0.2"
          message="Avoid excessively long variable names like {0}. Keep variable name length under {1}."
          class="PHPMD\Rule\Naming\LongVariable"
          externalInfoUrl="http://phpmd.org/rules/naming.html#longvariable">
        <priority>3</priority>
        <properties>
            <property name="maximum" description="The variable length reporting threshold" value="25"/>
        </properties>
    </rule>

    <rule ref="rulesets/codesize.xml/CyclomaticComplexity">
        <priority>1</priority>
        <properties>
            <property name="reportLevel" value="10"/>
        </properties>
    </rule>
</ruleset>