ILIAS  trunk Revision v11.0_alpha-2645-g16283d3b3f8
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.

References ilStartUpGUI\logoutUrl(), and ilSession\setClosingContext().

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

References $id.

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

◆ 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.

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

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

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
+ 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

Definition at line 35 of file ProvideWithdrawal.php.


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