| 1 | <?php |
||
| 14 | class ScriptAdapter implements ListenerInterfaceMpLegacyScript |
||
| 15 | { |
||
| 16 | /** @var Dispatcher */ |
||
| 17 | protected $dispatcher; |
||
| 18 | |||
| 19 | /** |
||
| 20 | * ScriptAdapter constructor. |
||
| 21 | * |
||
| 22 | * @param Dispatcher $dispatcher |
||
| 23 | */ |
||
| 24 | public function __construct(Dispatcher $dispatcher) |
||
| 28 | |||
| 29 | /** |
||
| 30 | * @param string $eventName Name of the event. |
||
| 31 | * @param mixed $parameters Parameters. |
||
| 32 | * |
||
| 33 | * @return mixed |
||
| 34 | */ |
||
| 35 | public function onModeScriptCallbackArray($eventName, $parameters) |
||
| 40 | |||
| 41 | /** |
||
| 42 | * Parse parameters that are usually in json. |
||
| 43 | * |
||
| 44 | * @param $parameters |
||
| 45 | * |
||
| 46 | * @return string|array |
||
| 47 | */ |
||
| 48 | protected function parseParameters($parameters) |
||
| 60 | } |
||
| 61 |