| 1 | <?php |
||
| 11 | class RuleCollection extends ArrayCollection |
||
| 12 | { |
||
| 13 | /** |
||
| 14 | * @param int|string $key |
||
| 15 | * @param Rule $value |
||
| 16 | */ |
||
| 17 | 7 | public function set($key, $value) |
|
| 23 | |||
| 24 | /** |
||
| 25 | * {@inheritdoc} |
||
| 26 | * @throw LogicException |
||
| 27 | */ |
||
| 28 | 1 | public function add($value) |
|
| 32 | |||
| 33 | /** |
||
| 34 | * Adds a rule collection at the end of the current set by appending all |
||
| 35 | * rule of the added collection. |
||
| 36 | * |
||
| 37 | * @param RuleCollection $collection A RuleCollection instance |
||
| 38 | */ |
||
| 39 | 1 | public function addCollection(RuleCollection $collection) |
|
| 45 | |||
| 46 | 7 | private function assertRuleInstance($value) |
|
| 55 | } |
||
| 56 |