Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
n/a
0 / 0
n/a
0 / 0
CRAP
n/a
0 / 0
1<?php
2/**
3 * Pop PHP Framework (https://www.popphp.org/)
4 *
5 * @link       https://github.com/popphp/popphp-framework
6 * @author     Nick Sagona, III <dev@noladev.com>
7 * @copyright  Copyright (c) 2009-2026 NOLA Interactive, LLC.
8 * @license    https://www.popphp.org/license     New BSD License
9 */
10
11/**
12 * @namespace
13 */
14namespace Pop;
15
16use ArrayIterator;
17
18/**
19 * Manager interface
20 *
21 * @category   Pop
22 * @package    Pop
23 * @author     Nick Sagona, III <dev@noladev.com>
24 * @copyright  Copyright (c) 2009-2026 NOLA Interactive, LLC.
25 * @license    https://www.popphp.org/license     New BSD License
26 * @version    4.4.0
27 */
28interface ManagerInterface
29{
30
31    /**
32     * Set items
33     *
34     * @param  array $items
35     * @return static
36     */
37    public function setItems(array $items): static;
38
39    /**
40     * Add items
41     *
42     * @param  array $items
43     * @return static
44     */
45    public function addItems(array $items): static;
46
47    /**
48     * Add an item
49     *
50     * @param  mixed $item
51     * @param  mixed $name
52     * @return static
53     */
54    public function addItem(mixed $item, mixed $name = null): static;
55
56    /**
57     * Remove an item
58     *
59     * @param  mixed $name
60     * @return static
61     */
62    public function removeItem(mixed $name): static;
63
64    /**
65     * Get an item
66     *
67     * @param  mixed $name
68     * @return mixed
69     */
70    public function getItem(mixed $name): mixed;
71
72    /**
73     * Determine whether the manager has an item
74     *
75     * @param  string $name
76     * @return bool
77     */
78    public function hasItem(string $name): bool;
79
80    /**
81     * Set an item
82     *
83     * @param  string $name
84     * @param  mixed  $value
85     * @return void
86     */
87    public function __set(string $name, mixed $value): void;
88
89    /**
90     * Get an item
91     *
92     * @param  string $name
93     * @return mixed
94     */
95    public function __get(string $name): mixed;
96
97    /**
98     * Determine if an item exists
99     *
100     * @param  string $name
101     * @return bool
102     */
103    public function __isset(string $name): bool;
104
105    /**
106     * Unset an item
107     *
108     * @param  string $name
109     * @return void
110     */
111    public function __unset(string $name): void;
112
113    /**
114     * Set an item
115     *
116     * @param  mixed $offset
117     * @param  mixed $value
118     * @return void
119     */
120    public function offsetSet(mixed $offset, mixed $value): void;
121
122    /**
123     * Get an item
124     *
125     * @param  mixed $offset
126     * @return mixed
127     */
128    public function offsetGet(mixed $offset): mixed;
129
130    /**
131     * Determine if an item exists
132     *
133     * @param  string $offset
134     * @return bool
135     */
136    public function offsetExists($offset): bool;
137
138    /**
139     * Unset an item
140     *
141     * @param  mixed $offset
142     * @return void
143     */
144    public function offsetUnset(mixed $offset): void;
145
146    /**
147     * Return count
148     *
149     * @return int
150     */
151    public function count(): int;
152
153    /**
154     * Get iterator
155     *
156     * @return ArrayIterator
157     */
158    public function getIterator(): ArrayIterator;
159
160}