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 (http://www.popphp.org/) |
4 | * |
5 | * @link https://github.com/popphp/popphp-framework |
6 | * @author Nick Sagona, III <dev@nolainteractive.com> |
7 | * @copyright Copyright (c) 2009-2024 NOLA Interactive, LLC. (http://www.nolainteractive.com) |
8 | * @license http://www.popphp.org/license New BSD License |
9 | */ |
10 | |
11 | /** |
12 | * @namespace |
13 | */ |
14 | namespace Pop\Filter; |
15 | |
16 | use Pop\Utils\CallableObject; |
17 | |
18 | /** |
19 | * Filter interface |
20 | * |
21 | * @category Pop |
22 | * @package Pop\Filter |
23 | * @author Nick Sagona, III <dev@nolainteractive.com> |
24 | * @copyright Copyright (c) 2009-2024 NOLA Interactive, LLC. (http://www.nolainteractive.com) |
25 | * @license http://www.popphp.org/license New BSD License |
26 | * @version 4.0.0 |
27 | */ |
28 | interface FilterInterface |
29 | { |
30 | |
31 | /** |
32 | * Set callable |
33 | * |
34 | * @param mixed $callable |
35 | * @return FilterInterface |
36 | */ |
37 | public function setCallable(mixed $callable): FilterInterface; |
38 | |
39 | /** |
40 | * Set params |
41 | * |
42 | * @param mixed $params |
43 | * @return FilterInterface |
44 | */ |
45 | public function setParams(mixed $params): FilterInterface; |
46 | |
47 | /** |
48 | * Set exclude by name |
49 | * |
50 | * @param mixed $excludeByName |
51 | * @return FilterInterface |
52 | */ |
53 | public function setExcludeByName(mixed $excludeByName): FilterInterface; |
54 | |
55 | /** |
56 | * Set exclude by type |
57 | * |
58 | * @param mixed $excludeByType |
59 | * @return FilterInterface |
60 | */ |
61 | public function setExcludeByType(mixed $excludeByType): FilterInterface; |
62 | |
63 | /** |
64 | * Get callable |
65 | * |
66 | * @return CallableObject |
67 | */ |
68 | public function getCallable(): CallableObject; |
69 | |
70 | /** |
71 | * Get params |
72 | * |
73 | * @return array |
74 | */ |
75 | public function getParams(): array; |
76 | |
77 | /** |
78 | * Get exclude by name |
79 | * |
80 | * @return array |
81 | */ |
82 | public function getExcludeByName(): array; |
83 | |
84 | /** |
85 | * Get exclude by type |
86 | * |
87 | * @return array |
88 | */ |
89 | public function getExcludeByType(): array; |
90 | |
91 | /** |
92 | * Has callable |
93 | * |
94 | * @return bool |
95 | */ |
96 | public function hasCallable(): bool; |
97 | |
98 | /** |
99 | * Has params |
100 | * |
101 | * @return bool |
102 | */ |
103 | public function hasParams(): bool; |
104 | |
105 | /** |
106 | * Has exclude by name |
107 | * |
108 | * @return bool |
109 | */ |
110 | public function hasExcludeByName(): bool; |
111 | |
112 | /** |
113 | * Has exclude by type |
114 | * |
115 | * @return bool |
116 | */ |
117 | public function hasExcludeByType(): bool; |
118 | |
119 | /** |
120 | * Filter value |
121 | * |
122 | * @param mixed $value |
123 | * @param ?string $name |
124 | * @param mixed $type |
125 | * @return mixed |
126 | */ |
127 | public function filter(mixed $value, ?string $name = null, mixed $type = null): mixed; |
128 | |
129 | } |