PHP Class ObjectCalisthenics\AbstractIdentifierLengthSniff

Show file Open project: object-calisthenics/phpcs-calisthenics-rules

Protected Properties

Property Type Description
$minLength integer Minimum variable/method name length.
$tokenString string Token string representation.
$tokenTypeLengthFactor integer Token type length factor, reducing the actual size of token by a factor of value.

Public Methods

Method Description
process ( PHP_CodeSniffer_File $phpcsFile, integer $stackPtr )
register ( ) : array

Protected Methods

Method Description
isValid ( PHP_CodeSniffer_File $phpcsFile, integer $stackPtr ) : boolean

Private Methods

Method Description
handleMinContentLength ( string $content )
isShortContentAllowed ( string $content ) : boolean

Method Details

isValid() abstract protected method

abstract protected isValid ( PHP_CodeSniffer_File $phpcsFile, integer $stackPtr ) : boolean
$phpcsFile PHP_CodeSniffer_File
$stackPtr integer
return boolean

process() public method

public process ( PHP_CodeSniffer_File $phpcsFile, integer $stackPtr )
$phpcsFile PHP_CodeSniffer_File
$stackPtr integer

register() public method

public register ( ) : array
return array

Property Details

$minLength protected property

Minimum variable/method name length.
protected int $minLength
return integer

$tokenString protected property

Token string representation.
protected string $tokenString
return string

$tokenTypeLengthFactor protected property

Token type length factor, reducing the actual size of token by a factor of value.
protected int $tokenTypeLengthFactor
return integer