1 | <?php |
||
18 | class Cut extends FilterRule |
||
19 | { |
||
20 | /** |
||
21 | * @var int |
||
22 | */ |
||
23 | private $start; |
||
24 | |||
25 | /** |
||
26 | * @var int|null |
||
27 | */ |
||
28 | private $length; |
||
29 | |||
30 | /** |
||
31 | * @param int $start |
||
32 | * @param int|null $length |
||
33 | */ |
||
34 | 4 | public function __construct($start, $length = null) |
|
39 | |||
40 | /** |
||
41 | * Cuts the given value |
||
42 | * |
||
43 | * @param mixed $value |
||
44 | * @return string |
||
45 | */ |
||
46 | 4 | public function filter($value) |
|
54 | } |
||
55 |