ILIAS  release_9 Revision v9.13-25-g2c18ec4c24f
class.ilHandler.php
Go to the documentation of this file.
1 <?php
2 
19 declare(strict_types=1);
20 
22 
23 use ILIAS\Export\ImportHandler\I\File\Namespace\ilHandlerInterface as ilParserNamespaceHandlerInterface;
24 
25 class ilHandler implements ilParserNamespaceHandlerInterface
26 {
27  protected string $prefix;
28  protected string $namespace;
29 
30  public function __construct()
31  {
32  $this->prefix = '';
33  $this->namespace = '';
34  }
35 
36  public function getPrefix(): string
37  {
38  return $this->prefix;
39  }
40 
41  public function getNamespace(): string
42  {
43  return $this->namespace;
44  }
45 
46  public function withPrefix(string $prefix): ilParserNamespaceHandlerInterface
47  {
48  $clone = clone $this;
49  $clone->prefix = $prefix;
50  return $clone;
51  }
52 
53  public function withNamespace(string $namespace): ilParserNamespaceHandlerInterface
54  {
55  $clone = clone $this;
56  $clone->namespace = $namespace;
57  return $clone;
58  }
59 }