1 | <?php |
||
21 | class CollectionMock extends \ArrayIterator implements CollectionIterator |
||
22 | { |
||
23 | const __CLASS = __CLASS__; |
||
24 | |||
25 | /** |
||
26 | * @param callable $callable |
||
27 | * @return mixed |
||
28 | */ |
||
29 | function walk(/*callable*/ $callable) |
||
35 | |||
36 | /** |
||
37 | * Returns raw data from database |
||
38 | * |
||
39 | * @return mixed |
||
40 | */ |
||
41 | function getRawData() |
||
45 | |||
46 | /** |
||
47 | * Returns number of iteration |
||
48 | * |
||
49 | * @return int |
||
50 | */ |
||
51 | function getIteration() |
||
55 | |||
56 | /** |
||
57 | * Returns total size of collection |
||
58 | * |
||
59 | * @return mixed |
||
60 | */ |
||
61 | function getSize() |
||
65 | |||
66 | } |
Adding explicit visibility (
private
,protected
, orpublic
) is generally recommend to communicate to other developers how, and from where this method is intended to be used.