PHP Класс sspmod_saml_Error, simplesamlphp

Наследование: extends SimpleSAML_Error_Exception
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
__construct ( string $status, string | null $subStatus = NULL, string | null $statusMessage = NULL, Exception $cause = NULL ) Create a SAML 2 error.
fromException ( Exception $exception ) : sspmod_saml_Error Create a SAML2 error from an exception.
getStatus ( ) : string Get the top-level status code.
getStatusMessage ( ) : string | null Get the status message.
getSubStatus ( ) : string | null Get the second-level status code.
toException ( ) : SimpleSAML_Error_Exception Create a normal exception from a SAML2 error.

Приватные методы

Метод Описание
shortStatus ( string $status ) : string Create a short version of the status code.

Описание методов

__construct() публичный Метод

Create a SAML 2 error.
public __construct ( string $status, string | null $subStatus = NULL, string | null $statusMessage = NULL, Exception $cause = NULL )
$status string The top-level status code.
$subStatus string | null The second-level status code. Can be NULL, in which case there is no second-level status code.
$statusMessage string | null The status message. Can be NULL, in which case there is no status message.
$cause Exception The cause of this exception. Can be NULL.

fromException() публичный статический Метод

This function attempts to create a SAML2 error with the appropriate status codes from an arbitrary exception.
public static fromException ( Exception $exception ) : sspmod_saml_Error
$exception Exception The original exception.
Результат sspmod_saml_Error The new exception.

getStatus() публичный Метод

Get the top-level status code.
public getStatus ( ) : string
Результат string The top-level status code.

getStatusMessage() публичный Метод

Get the status message.
public getStatusMessage ( ) : string | null
Результат string | null The status message or NULL if no status message is present.

getSubStatus() публичный Метод

Get the second-level status code.
public getSubStatus ( ) : string | null
Результат string | null The second-level status code or NULL if no second-level status code is present.

toException() публичный Метод

This function attempts to reverse the operation of the fromException() function. If it is unable to create a more specific exception, it will return the current object.
См. также: sspmod_saml_Error::fromException()
public toException ( ) : SimpleSAML_Error_Exception
Результат SimpleSAML_Error_Exception An exception representing this error.