ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
ILIAS\LegalDocuments\Provide\ProvideWithdrawal Class Reference
+ Collaboration diagram for ILIAS\LegalDocuments\Provide\ProvideWithdrawal:

Public Member Functions

 __construct (private readonly string $id, private readonly ilCtrlInterface $ctrl, private readonly ilAuthSession $auth_session, ?Closure $logout_url=null, ?Closure $close_session_context=null)
 
 beginProcessURL ()
 
 finishAndLogout (array $additional_url_parameters=[])
 

Private Attributes

readonly Closure $close_session_context
 
readonly Closure $logout_url
 

Detailed Description

Definition at line 29 of file ProvideWithdrawal.php.

Constructor & Destructor Documentation

◆ __construct()

ILIAS\LegalDocuments\Provide\ProvideWithdrawal::__construct ( private readonly string  $id,
private readonly ilCtrlInterface  $ctrl,
private readonly ilAuthSession  $auth_session,
?Closure  $logout_url = null,
?Closure  $close_session_context = null 
)
Parameters
null|Closure(array<string|int,string|int>)string $logout_url
null|Closure(int)void $close_session_context

Definition at line 41 of file ProvideWithdrawal.php.

47 {
48 $this->logout_url = $logout_url ?? ilStartUpGUI::logoutUrl(...);
49 $this->close_session_context = $close_session_context ?? ilSession::setClosingContext(...);
50 }
static setClosingContext(int $a_context)
set closing context (for statistics)
static logoutUrl(array $parameters=[])
Return the logout URL with a valid CSRF token.

References ILIAS\LegalDocuments\Provide\ProvideWithdrawal\$close_session_context, ILIAS\LegalDocuments\Provide\ProvideWithdrawal\$logout_url, ilStartUpGUI\logoutUrl(), and ilSession\setClosingContext().

+ Here is the call graph for this function:

Member Function Documentation

◆ beginProcessURL()

ILIAS\LegalDocuments\Provide\ProvideWithdrawal::beginProcessURL ( )

Definition at line 52 of file ProvideWithdrawal.php.

52 : string
53 {
54 return ($this->logout_url)(['withdraw_consent' => $this->id]);
55 }
$id
plugin.php for ilComponentBuildPluginInfoObjectiveTest::testAddPlugins
Definition: plugin.php:23

References $id.

◆ finishAndLogout()

ILIAS\LegalDocuments\Provide\ProvideWithdrawal::finishAndLogout ( array  $additional_url_parameters = [])
Parameters
array<string,string>$additional_url_parameters

Definition at line 60 of file ProvideWithdrawal.php.

60 : void
61 {
63 $this->auth_session->logout();
64
65 $this->ctrl->redirectToURL('login.php?' . http_build_query(array_merge($additional_url_parameters, [
66 'withdrawal_finished' => $this->id,
67 'cmd' => 'force_login',
68 ])));
69 }
const int SESSION_CLOSE_USER

References ILIAS\LegalDocuments\Provide\ProvideWithdrawal\$close_session_context, ILIAS\Repository\ctrl(), and ilSession\SESSION_CLOSE_USER.

Referenced by ILIAS\LegalDocuments\test\Provide\ProvideWithdrawalTest\testFinishAndLogout().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Field Documentation

◆ $close_session_context

readonly Closure ILIAS\LegalDocuments\Provide\ProvideWithdrawal::$close_session_context
private

◆ $logout_url

readonly Closure ILIAS\LegalDocuments\Provide\ProvideWithdrawal::$logout_url
private

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