MediaWiki REL1_34
LocalizedException Class Reference

Basic localized exception. More...

Inheritance diagram for LocalizedException:
Collaboration diagram for LocalizedException:

Public Member Functions

 __construct ( $messageSpec, $code=0, $previous=null)
 
 getMessageObject ()
 Return a Message object for this exception.
 

Protected Attributes

string array MessageSpecifier $messageSpec
 

Detailed Description

Basic localized exception.

Since
1.29
Note
Don't use this in a situation where MessageCache is not functional.

Definition at line 28 of file LocalizedException.php.

Constructor & Destructor Documentation

◆ __construct()

LocalizedException::__construct (   $messageSpec,
  $code = 0,
  $previous = null 
)
Parameters
string | array | MessageSpecifier$messageSpecSee Message::newFromSpecifier
int$code
Exception | Throwable | null$previousThe previous exception used for the exception chaining.

Definition at line 38 of file LocalizedException.php.

References $messageSpec, and getMessageObject().

Member Function Documentation

◆ getMessageObject()

LocalizedException::getMessageObject ( )

Return a Message object for this exception.

Returns
Message

Implements ILocalizedException.

Definition at line 50 of file LocalizedException.php.

References Message\newFromSpecifier().

Referenced by __construct().

Member Data Documentation

◆ $messageSpec

string array MessageSpecifier LocalizedException::$messageSpec
protected

Definition at line 30 of file LocalizedException.php.

Referenced by __construct().


The documentation for this class was generated from the following file: