ILIAS  trunk Revision v11.0_alpha-1831-g8615d53dadb
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
ILIAS\Mail\Placeholder\AbstractPlaceholderHandler Class Reference
+ Inheritance diagram for ILIAS\Mail\Placeholder\AbstractPlaceholderHandler:
+ Collaboration diagram for ILIAS\Mail\Placeholder\AbstractPlaceholderHandler:

Public Member Functions

 __construct (protected ilLanguage $lng)
 
 getLabel ()
 
 setNext (Placeholder $next)
 
 getNext ()
 
 handle (Signature $signature)
 
 addPlaceholder (array $placeholder)
 
- Public Member Functions inherited from ILIAS\Mail\Placeholder\Placeholder
 getId ()
 
 setNext (self $next)
 

Protected Attributes

Placeholder $next = null
 

Detailed Description

Definition at line 26 of file AbstractPlaceholderHandler.php.

Constructor & Destructor Documentation

◆ __construct()

ILIAS\Mail\Placeholder\AbstractPlaceholderHandler::__construct ( protected ilLanguage  $lng)

Definition at line 30 of file AbstractPlaceholderHandler.php.

31  {
32  }

Member Function Documentation

◆ addPlaceholder()

ILIAS\Mail\Placeholder\AbstractPlaceholderHandler::addPlaceholder ( array  $placeholder)
abstract
Parameters
Placeholder[]$placeholder
Returns
array<string, string>

Referenced by ILIAS\Mail\Placeholder\AbstractPlaceholderHandler\handle().

+ Here is the caller graph for this function:

◆ getLabel()

ILIAS\Mail\Placeholder\AbstractPlaceholderHandler::getLabel ( )

Implements ILIAS\Mail\Placeholder\Placeholder.

Definition at line 34 of file AbstractPlaceholderHandler.php.

References ILIAS\Mail\Placeholder\Placeholder\getId(), and ILIAS\Repository\lng().

34  : string
35  {
36  return $this->lng->txt('mail_nacc_' . strtolower($this->getId()));
37  }
+ Here is the call graph for this function:

◆ getNext()

ILIAS\Mail\Placeholder\AbstractPlaceholderHandler::getNext ( )

◆ handle()

ILIAS\Mail\Placeholder\AbstractPlaceholderHandler::handle ( Signature  $signature)
Parameters
Signature$signature
Returns
string<string, string>

Implements ILIAS\Mail\Placeholder\Placeholder.

Definition at line 55 of file AbstractPlaceholderHandler.php.

References ILIAS\Mail\Placeholder\AbstractPlaceholderHandler\addPlaceholder(), ILIAS\User\Profile\next, and ILIAS\Mail\Signature\Signature\supports().

55  : array
56  {
57  $placeholders = [];
58 
59  if ($this->next) {
60  $placeholders = $this->next->handle($signature);
61  }
62 
63  if ($signature->supports($this)) {
64  $placeholders = $this->addPlaceholder($placeholders);
65  }
66 
67  return $placeholders;
68  }
+ Here is the call graph for this function:

◆ setNext()

ILIAS\Mail\Placeholder\AbstractPlaceholderHandler::setNext ( Placeholder  $next)

Field Documentation

◆ $next

Placeholder ILIAS\Mail\Placeholder\AbstractPlaceholderHandler::$next = null
protected

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