ILIAS  trunk Revision v12.0_alpha-377-g3641b37b9db
ILIAS\ApacheAuth\UsernameProvider\Username Class Reference
+ Inheritance diagram for ILIAS\ApacheAuth\UsernameProvider\Username:
+ Collaboration diagram for ILIAS\ApacheAuth\UsernameProvider\Username:

Public Member Functions

 __construct (private string $username)
 
 asString ()
 Returns the username as string. More...
 
 isEmpty ()
 True if this represents an empty (non-real) username. More...
 
 __toString ()
 
 asString ()
 Returns the username as string. More...
 
 isEmpty ()
 True if this represents an empty (non-real) username. More...
 

Detailed Description

Definition at line 23 of file Username.php.

Constructor & Destructor Documentation

◆ __construct()

ILIAS\ApacheAuth\UsernameProvider\Username::__construct ( private string  $username)

Definition at line 25 of file Username.php.

26 {
27 if (trim($username) === '') {
28 throw new \InvalidArgumentException('Username cannot be empty');
29 }
30 }

Member Function Documentation

◆ __toString()

ILIAS\ApacheAuth\UsernameProvider\Username::__toString ( )

Definition at line 42 of file Username.php.

42 : string
43 {
44 return $this->username;
45 }

Referenced by ILIAS\ApacheAuth\UsernameProvider\Username\asString().

+ Here is the caller graph for this function:

◆ asString()

ILIAS\ApacheAuth\UsernameProvider\Username::asString ( )

Returns the username as string.

Implements ILIAS\ApacheAuth\UsernameProvider\UsernameInterface.

Definition at line 32 of file Username.php.

32 : string
33 {
34 return $this->__toString();
35 }

References ILIAS\ApacheAuth\UsernameProvider\Username\__toString().

+ Here is the call graph for this function:

◆ isEmpty()

ILIAS\ApacheAuth\UsernameProvider\Username::isEmpty ( )

True if this represents an empty (non-real) username.

Implements ILIAS\ApacheAuth\UsernameProvider\UsernameInterface.

Definition at line 37 of file Username.php.

37 : bool
38 {
39 return false;
40 }

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