PHP Class Pantheon\Terminus\Exceptions\TerminusException

Inheritance: extends Exception
Mostrar archivo Open project: pantheon-systems/terminus

Public Methods

Method Description
__construct ( string $message = null, array $replacements = [], integer $code ) Object constructor. Sets context array as replacements property
getRawMessage ( ) : string Returns the replacements context array
getReplacements ( ) : array Returns the replacements context array

Protected Methods

Method Description
interpolateString ( string $message, array $replacements ) : string Replace the variables into the message string.

Method Details

__construct() public method

Object constructor. Sets context array as replacements property
public __construct ( string $message = null, array $replacements = [], integer $code )
$message string Message to send when throwing the exception
$replacements array Context array to interpolate into message
$code integer Exit code

getRawMessage() public method

Returns the replacements context array
public getRawMessage ( ) : string
return string $this->replacements

getReplacements() public method

Returns the replacements context array
public getReplacements ( ) : array
return array $this->replacements The replacement variables.

interpolateString() protected method

Replace the variables into the message string.
protected interpolateString ( string $message, array $replacements ) : string
$message string The raw, uninterpolated message string
$replacements array The values to replace into the message
return string