TYPO3  7.6
Public Member Functions | Public Attributes | Protected Attributes | List of all members
Status Class Reference

Public Member Functions

 __construct ($title, $value, $message= '', $severity=self::OK)
 
 getTitle ()
 
 getValue ()
 
 getMessage ()
 
 getSeverity ()
 
 __toString ()
 

Public Attributes

const NOTICE = -2
 
const INFO = -1
 
const OK = 0
 
const WARNING = 1
 
const ERROR = 2
 

Protected Attributes

 $title
 
 $value
 
 $message
 
 $severity
 

Detailed Description

A class representing a certain status

Definition at line 20 of file Status.php.

Constructor & Destructor Documentation

__construct (   $title,
  $value,
  $message = '',
  $severity = self::OK 
)

Construct a status

All values must be given as constructor arguments. All strings should be localized.

Parameters
string$titleStatus title, eg. "Deprecation log"
string$valueStatus value, eg. "Disabled"
string$messageOptional message further describing the title/value combination Example:, eg "The deprecation log is important and does foo, to disable it do bar"
int$severityA severity level. Use one of the constants above!

Definition at line 60 of file Status.php.

References Status\$message, Status\$severity, Status\$title, and Status\$value.

Member Function Documentation

__toString ( )

Creates a string representation of a status.

Returns
string String representation of this status.

Definition at line 113 of file Status.php.

References Status\$severity.

getMessage ( )

Gets the status' message (if any)

Returns
string

Definition at line 93 of file Status.php.

References Status\$message.

getSeverity ( )

Gets the status' severity

Returns
int

Definition at line 103 of file Status.php.

References Status\$severity.

getTitle ( )

Gets the status' title

Returns
string

Definition at line 73 of file Status.php.

References Status\$title.

getValue ( )

Gets the status' value

Returns
string

Definition at line 83 of file Status.php.

References Status\$value.

Member Data Documentation

$message
protected

Definition at line 41 of file Status.php.

Referenced by Status\__construct(), and Status\getMessage().

$severity
protected

Definition at line 46 of file Status.php.

Referenced by Status\__construct(), Status\__toString(), and Status\getSeverity().

$title
protected

Definition at line 31 of file Status.php.

Referenced by Status\__construct(), and Status\getTitle().

$value
protected

Definition at line 36 of file Status.php.

Referenced by Status\__construct(), and Status\getValue().

const ERROR = 2
const INFO = -1

Definition at line 23 of file Status.php.

const NOTICE = -2
const OK = 0
const WARNING = 1