ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
Factory.php
Go to the documentation of this file.
1<?php
2
19declare(strict_types=1);
20
22
27
28class Factory implements FactoryInterface
29{
30 public function standard(SlotIdentifier $slot, string ...$values): BuilderInterface
31 {
32 return new Builder(
33 $slot,
34 Type::STANDARD,
35 $slot->value,
37 ...$values
38 );
39 }
40
41 public function controlledString(
42 SlotIdentifier $slot,
43 string $id,
44 string $source,
45 string ...$values
47 return new Builder($slot, Type::CONTROLLED_STRING, $id, $source, ...$values);
48 }
49
50 public function controlledVocabValue(
51 SlotIdentifier $slot,
52 string $id,
53 string $source,
54 string ...$values
56 return new Builder($slot, Type::CONTROLLED_VOCAB_VALUE, $id, $source, ...$values);
57 }
58
59 public function copyright(string ...$values): BuilderInterface
60 {
61 return new Builder(
62 SlotIdentifier::RIGHTS_DESCRIPTION,
64 SlotIdentifier::RIGHTS_DESCRIPTION->value,
65 FactoryInterface::COPYRIGHT_SOURCE,
66 ...$values
67 );
68 }
69
70 public function null(): VocabularyInterface
71 {
72 return new NullVocabulary();
73 }
74}
$id
plugin.php for ilComponentBuildPluginInfoObjectiveTest::testAddPlugins
Definition: plugin.php:23
controlledVocabValue(SlotIdentifier $slot, string $id, string $source, string ... $values)
Definition: Factory.php:50
standard(SlotIdentifier $slot, string ... $values)
Definition: Factory.php:30
controlledString(SlotIdentifier $slot, string $id, string $source, string ... $values)
Definition: Factory.php:41
return['delivery_method'=> 'php',]
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...