ILIAS  trunk Revision v13.0_alpha-62-g3b72d83f2e5
ILIAS\Questions\Persistence\TableSubNameSpace Class Reference
+ Collaboration diagram for ILIAS\Questions\Persistence\TableSubNameSpace:

Public Member Functions

 __construct (private readonly string $vendor, private readonly string $sub_name_space)
 
 get ()
 

Detailed Description

Definition at line 23 of file TableSubNameSpace.php.

Constructor & Destructor Documentation

◆ __construct()

ILIAS\Questions\Persistence\TableSubNameSpace::__construct ( private readonly string  $vendor,
private readonly string  $sub_name_space 
)
Parameters
string$vendorMaximum four characters used to create the tables
string$sub_name_spaceMaximum eight characters used to create the tables

Definition at line 29 of file TableSubNameSpace.php.

32 {
33 if ($vendor === ''
34 || $sub_name_space === ''
35 || mb_strlen($vendor) > 6
36 || mb_strlen($sub_name_space) > 8) {
37 throw new \InvalidArgumentException(
38 '$vendor cannot be empty or longer than 6, '
39 . '$sub_name_space cannot be empty or longer than 8 characters.'
40 );
41 }
42 }

Member Function Documentation

◆ get()

ILIAS\Questions\Persistence\TableSubNameSpace::get ( )

Definition at line 44 of file TableSubNameSpace.php.

44 : string
45 {
46 if ($this->vendor === 'ILIAS') {
47 return $this->sub_name_space;
48 }
49 return "{$this->vendor}_{$this->sub_name_space}";
50 }

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