ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
SimpleSAML_Error_AuthSource Class Reference
+ Inheritance diagram for SimpleSAML_Error_AuthSource:
+ Collaboration diagram for SimpleSAML_Error_AuthSource:

Public Member Functions

 __construct ($authsource, $reason, $cause=null)
 Create a new AuthSource error. More...
 
 getAuthSource ()
 Retrieve the authsource module name from where this error was thrown. More...
 
 getReason ()
 Retrieve the reason why the request was invalid. More...
 
- Public Member Functions inherited from SimpleSAML_Error_Error
 __construct ($errorCode, Exception $cause=null, $httpCode=null)
 Constructor for this error. More...
 
 getErrorCode ()
 Retrieve the error code given when throwing this error. More...
 
 getParameters ()
 Retrieve the error parameters given when throwing this error. More...
 
 getDictTitle ()
 Retrieve the error title tag in dictionary. More...
 
 getDictDescr ()
 Retrieve the error description tag in dictionary. More...
 
 show ()
 Display this error. More...
 
- Public Member Functions inherited from SimpleSAML_Error_Exception
 __construct ($message, $code=0, Exception $cause=null)
 Constructor for this error. More...
 
 getBacktrace ()
 Retrieve the backtrace. More...
 
 getCause ()
 Retrieve the cause of this exception. More...
 
 getClass ()
 Retrieve the class of this exception. More...
 
 format ($anonymize=false)
 Format this exception for logging. More...
 
 formatBacktrace ($anonymize=false)
 Format the backtrace for logging. More...
 
 log ($default_level)
 Print the exception to the log, by default with log level error. More...
 
 logError ()
 Print the exception to the log with log level error. More...
 
 logWarning ()
 Print the exception to the log with log level warning. More...
 
 logInfo ()
 Print the exception to the log with log level info. More...
 
 logDebug ()
 Print the exception to the log with log level debug. More...
 
 __sleep ()
 Function for serialization. More...
 

Private Attributes

 $authsource
 Authsource module name. More...
 
 $reason
 Reason why this request was invalid. More...
 

Additional Inherited Members

- Static Public Member Functions inherited from SimpleSAML_Error_Exception
static fromException (Exception $e)
 Convert any exception into a SimpleSAML_Error_Exception. More...
 
- Protected Member Functions inherited from SimpleSAML_Error_Error
 setHTTPCode ()
 Set the HTTP return code for this error. More...
 
 saveError ()
 Save an error report. More...
 
- Protected Member Functions inherited from SimpleSAML_Error_Exception
 initBacktrace (Exception $exception)
 Load the backtrace from the given exception. More...
 
 logBacktrace ($level=\SimpleSAML\Logger::DEBUG)
 Print the backtrace to the log if the 'debug' option is enabled in the configuration. More...
 
- Protected Attributes inherited from SimpleSAML_Error_Error
 $httpCode = 500
 
 $includeTemplate = null
 

Detailed Description

Definition at line 8 of file AuthSource.php.

Constructor & Destructor Documentation

◆ __construct()

SimpleSAML_Error_AuthSource::__construct (   $authsource,
  $reason,
  $cause = null 
)

Create a new AuthSource error.

Parameters
string$authsourceAuthsource module name from where this error was thrown.
string$reasonDescription of the error.

Definition at line 30 of file AuthSource.php.

References $authsource, SimpleSAML_Error_Exception\$cause, and $reason.

31  {
32  assert(is_string($authsource));
33  assert(is_string($reason));
34 
35  $this->authsource = $authsource;
36  $this->reason = $reason;
37  parent::__construct(
38  array(
39  'AUTHSOURCEERROR',
40  '%AUTHSOURCE%' => htmlspecialchars(var_export($this->authsource, true)),
41  '%REASON%' => htmlspecialchars(var_export($this->reason, true))
42  ),
43  $cause
44  );
45 
46  $this->message = "Error with authentication source '$authsource': $reason";
47  }
$authsource
Authsource module name.
Definition: AuthSource.php:15
$reason
Reason why this request was invalid.
Definition: AuthSource.php:21

Member Function Documentation

◆ getAuthSource()

SimpleSAML_Error_AuthSource::getAuthSource ( )

Retrieve the authsource module name from where this error was thrown.

Returns
string Authsource module name.

Definition at line 55 of file AuthSource.php.

References $authsource.

56  {
57  return $this->authsource;
58  }
$authsource
Authsource module name.
Definition: AuthSource.php:15

◆ getReason()

SimpleSAML_Error_AuthSource::getReason ( )

Retrieve the reason why the request was invalid.

Returns
string The reason why the request was invalid.

Definition at line 66 of file AuthSource.php.

References $reason.

67  {
68  return $this->reason;
69  }
$reason
Reason why this request was invalid.
Definition: AuthSource.php:21

Field Documentation

◆ $authsource

SimpleSAML_Error_AuthSource::$authsource
private

Authsource module name.

Definition at line 15 of file AuthSource.php.

Referenced by __construct(), and getAuthSource().

◆ $reason

SimpleSAML_Error_AuthSource::$reason
private

Reason why this request was invalid.

Definition at line 21 of file AuthSource.php.

Referenced by __construct(), and getReason().


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