oont-contents/plugins/wpify-woo/deps/php-di/invoker/src/InvokerInterface.php
2025-02-08 15:10:23 +01:00

25 lines
778 B
PHP

<?php
declare (strict_types=1);
namespace WpifyWooDeps\Invoker;
use WpifyWooDeps\Invoker\Exception\InvocationException;
use WpifyWooDeps\Invoker\Exception\NotCallableException;
use WpifyWooDeps\Invoker\Exception\NotEnoughParametersException;
/**
* Invoke a callable.
*/
interface InvokerInterface
{
/**
* Call the given function using the given parameters.
*
* @param callable|array|string $callable Function to call.
* @param array $parameters Parameters to use.
* @return mixed Result of the function.
* @throws InvocationException Base exception class for all the sub-exceptions below.
* @throws NotCallableException
* @throws NotEnoughParametersException
*/
public function call($callable, array $parameters = []);
}