1 | <?php namespace Anomaly\Streams\Platform\Image; |
||
13 | class ImageMacros |
||
14 | { |
||
15 | |||
16 | /** |
||
17 | * Registered macros. |
||
18 | * |
||
19 | * @var array |
||
20 | */ |
||
21 | protected $macros; |
||
22 | |||
23 | /** |
||
24 | * The service container. |
||
25 | * |
||
26 | * @var Container |
||
27 | */ |
||
28 | protected $container; |
||
29 | |||
30 | /** |
||
31 | * Create a new ImageMacros instance. |
||
32 | * |
||
33 | * @param Container $container |
||
34 | * @param Repository $config |
||
35 | */ |
||
36 | public function __construct(Repository $config, Container $container) |
||
41 | |||
42 | /** |
||
43 | * Run a macro. |
||
44 | * |
||
45 | * @param $macro |
||
46 | * @param Image $image |
||
47 | * @return Image |
||
48 | * @throws \Exception |
||
49 | */ |
||
50 | public function run($macro, Image $image) |
||
68 | |||
69 | /** |
||
70 | * Get the macros. |
||
71 | * |
||
72 | * @return array|mixed |
||
73 | */ |
||
74 | public function getMacros() |
||
78 | |||
79 | /** |
||
80 | * Set the macros. |
||
81 | * |
||
82 | * @param array $macros |
||
83 | * @return $this |
||
84 | */ |
||
85 | public function setMacros(array $macros) |
||
91 | |||
92 | /** |
||
93 | * Add an image macro hint. |
||
94 | * |
||
95 | * @param $namespace |
||
96 | * @param $macro |
||
97 | * @return $this |
||
98 | */ |
||
99 | public function addMacro($macro, $process) |
||
105 | |||
106 | /** |
||
107 | * Return if a macro exists or not. |
||
108 | * |
||
109 | * @param $macro |
||
110 | * @return bool |
||
111 | */ |
||
112 | public function isMacro($macro) |
||
116 | } |
||
117 |
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..