PHP Class HippoPHP\Hippo\Violation

Author: James Brooks ([email protected])
Afficher le fichier Open project: hippophp/hippo Class Usage Examples

Protected Properties

Свойство Type Description
$column integer The column that the violation occurred on.
$file File The file that the violation was made on.
$line integer The line number that the violation was made on.
$message string The violation text.
$severity integer The severity of the error.

Méthodes publiques

Méthode Description
__construct ( File $file, integer $line, integer $column, integer $severity, string $message ) Creates a new violation.
getColumn ( ) : integer Returns the column number of the violation.
getFile ( ) : File Returns the file of the violation.
getLine ( ) : integer Returns the line number of the violation.
getMessage ( ) : string Returns the violations message.
getSeverities ( ) : int[] Violation severities, in order from most deadly to most peaceful.
getSeverity ( ) : integer Returns the severity of the violation.
getSeverityFromString ( string $severityName ) : integer Get a severity level from a severity name.
getSeverityName ( ) : string Returns the named value of the severity.

Private Methods

Méthode Description
getSeverityNames ( ) : array Array of severity levels to the severity name.

Method Details

__construct() public méthode

Creates a new violation.
public __construct ( File $file, integer $line, integer $column, integer $severity, string $message )
$file File
$line integer
$column integer
$severity integer
$message string

getColumn() public méthode

Returns the column number of the violation.
public getColumn ( ) : integer
Résultat integer

getFile() public méthode

Returns the file of the violation.
public getFile ( ) : File
Résultat File

getLine() public méthode

Returns the line number of the violation.
public getLine ( ) : integer
Résultat integer

getMessage() public méthode

Returns the violations message.
public getMessage ( ) : string
Résultat string

getSeverities() public static méthode

Violation severities, in order from most deadly to most peaceful.
public static getSeverities ( ) : int[]
Résultat int[]

getSeverity() public méthode

Returns the severity of the violation.
public getSeverity ( ) : integer
Résultat integer

getSeverityFromString() public static méthode

Get a severity level from a severity name.
public static getSeverityFromString ( string $severityName ) : integer
$severityName string
Résultat integer

getSeverityName() public méthode

Returns the named value of the severity.
public getSeverityName ( ) : string
Résultat string

Property Details

$column protected_oe property

The column that the violation occurred on.
protected int $column
Résultat integer

$file protected_oe property

The file that the violation was made on.
protected File,HippoPHP\Hippo $file
Résultat File

$line protected_oe property

The line number that the violation was made on.
protected int $line
Résultat integer

$message protected_oe property

The violation text.
protected string $message
Résultat string

$severity protected_oe property

The severity of the error.
protected int $severity
Résultat integer