Auth
5 months ago
Cookie
5 months ago
Exception
5 months ago
Proxy
5 months ago
Response
5 months ago
Transport
5 months ago
Utility
5 months ago
Auth.php
5 months ago
Autoload.php
5 months ago
Capability.php
5 months ago
Cookie.php
5 months ago
Exception.php
5 months ago
HookManager.php
5 months ago
Hooks.php
5 months ago
IdnaEncoder.php
5 months ago
Ipv6.php
5 months ago
Iri.php
5 months ago
Port.php
5 months ago
Proxy.php
5 months ago
Requests.php
5 months ago
Response.php
5 months ago
Session.php
5 months ago
Ssl.php
5 months ago
Transport.php
5 months ago
HookManager.php
34 lines
| 1 | <?php |
| 2 | /** |
| 3 | * Event dispatcher |
| 4 | * |
| 5 | * @package Requests\EventDispatcher |
| 6 | */ |
| 7 | |
| 8 | namespace AmeliaVendor\WpOrg\Requests; |
| 9 | |
| 10 | /** |
| 11 | * Event dispatcher |
| 12 | * |
| 13 | * @package Requests\EventDispatcher |
| 14 | */ |
| 15 | interface HookManager { |
| 16 | /** |
| 17 | * Register a callback for a hook |
| 18 | * |
| 19 | * @param string $hook Hook name |
| 20 | * @param callable $callback Function/method to call on event |
| 21 | * @param int $priority Priority number. <0 is executed earlier, >0 is executed later |
| 22 | */ |
| 23 | public function register($hook, $callback, $priority = 0); |
| 24 | |
| 25 | /** |
| 26 | * Dispatch a message |
| 27 | * |
| 28 | * @param string $hook Hook name |
| 29 | * @param array $parameters Parameters to pass to callbacks |
| 30 | * @return boolean Successfulness |
| 31 | */ |
| 32 | public function dispatch($hook, $parameters = []); |
| 33 | } |
| 34 |