ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
ILIAS\Component\Dependencies\Name Class Reference
+ Collaboration diagram for ILIAS\Component\Dependencies\Name:

Public Member Functions

 __construct (protected string $name)
 
 __toString ()
 

Private Attributes

const PROPER_NAME_REGEXP = "/\w+([\\\\]\w+){2,}/"
 

Detailed Description

Definition at line 23 of file Name.php.

Constructor & Destructor Documentation

◆ __construct()

ILIAS\Component\Dependencies\Name::__construct ( protected string  $name)

Definition at line 27 of file Name.php.

29 {
30 if (!preg_match(self::PROPER_NAME_REGEXP, $this->name)) {
31 throw new \InvalidArgumentException(
32 "{$this->name} is not a proper name for a dependency."
33 );
34 }
35 }

Member Function Documentation

◆ __toString()

ILIAS\Component\Dependencies\Name::__toString ( )

Definition at line 37 of file Name.php.

37 : string
38 {
39 return $this->name;
40 }

Field Documentation

◆ PROPER_NAME_REGEXP

const ILIAS\Component\Dependencies\Name::PROPER_NAME_REGEXP = "/\w+([\\\\]\w+){2,}/"
private

Definition at line 25 of file Name.php.


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