[TASK] Re-work/simplify copyright header in PHP files - Part 2
[Packages/TYPO3.CMS.git] / typo3 / sysext / core / Classes / Collection / EditableCollectionInterface.php
1 <?php
2 namespace TYPO3\CMS\Core\Collection;
3
4 /**
5 * This file is part of the TYPO3 CMS project.
6 *
7 * It is free software; you can redistribute it and/or modify it under
8 * the terms of the GNU General Public License, either version 2
9 * of the License, or any later version.
10 *
11 * For the full copyright and license information, please read the
12 * LICENSE.txt file that was distributed with this source code.
13 *
14 * The TYPO3 project - inspiring people to share!
15 */
16 /**
17 * Interface for collection classes which es enabled to be modified
18 *
19 * @author Steffen Ritter <typo3steffen-ritter.net>
20 */
21 interface EditableCollectionInterface
22 {
23 /**
24 * Adds on entry to the collection
25 *
26 * @param mixed $data
27 * @return void
28 */
29 public function add($data);
30
31 /**
32 * Adds a set of entries to the collection
33 *
34 * @param \TYPO3\CMS\Core\Collection\CollectionInterface $other
35 * @return void
36 */
37 public function addAll(\TYPO3\CMS\Core\Collection\CollectionInterface $other);
38
39 /**
40 * Remove the given entry from collection
41 *
42 * Note: not the given "index"
43 *
44 * @param mixed $data
45 * @return void
46 */
47 public function remove($data);
48
49 /**
50 * Removes all entries from the collection
51 *
52 * collection will be empty afterwards
53 *
54 * @return void
55 */
56 public function removeAll();
57
58 }