DispatcherInterface
Contract for WebSocket task dispatchers.
This combines Phalcon's native CLI dispatcher surface with PhalconKit's shared dispatcher helpers so WebSocket tasks can be resolved and inspected through the same contract as CLI tasks.
- Full name:
\PhalconKit\Ws\DispatcherInterface - Parent interfaces:
Dispatcher,\PhalconKit\Dispatcher\DispatcherInterface
Inherited methods
canForward
Determine whether a forward target differs from the effective dispatch.
public canForward(array<string,mixed> $forward): bool
Resolve empty namespace/handler/action names to dispatcher defaults and preserve null/omitted parts without changing the live dispatch state. Module and parameter values remain part of the comparison. Controller takes precedence over task, matching native forward() in either mode. This is used by listeners that forward to error, maintenance, or unauthorized routes and need to avoid forwarding back to themselves.
Parameters:
| Parameter | Type | Description |
|---|---|---|
$forward | array | Forward route parts. |
toArray
Export dispatcher state for logs, diagnostics, and tests.
public toArray(): array<string,mixed>