summaryrefslogtreecommitdiff
path: root/Zend/zend_interfaces.stub.php
blob: b78257f53f0c66c0979863834cf235c5c500fbf8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
<?php

interface Traversable {}

interface IteratorAggregate extends Traversable
{
    /** @return Traversable */
    function getIterator();
}

interface Iterator extends Traversable
{
    /** @return mixed */
    function current();

    /** @return void */
    function next();

    /** @return mixed */
    function key();

    /** @return bool */
    function valid();

    /** @return void */
    function rewind();
}

interface ArrayAccess
{
    /** @return bool */
    function offsetExists($offset);

    /* actually this should be return by ref but atm cannot be */
    /** @return mixed */
    function offsetGet($offset);

    /** @return void */
    function offsetSet($offset, $value);

    /** @return void */
    function offsetUnset($offset);
}

interface Serializable
{
    /** @return string */
    function serialize();

    /** @return void */
    function unserialize(string $serialized);
}

interface Countable
{
    /** @return int */
    function count();
}

interface Stringable
{
    function __toString(): string;
}