| Methods |
public
static
|
createPair(): array{self, self}
|
#
|
public
|
start(): void
Begins consuming inbound envelopes from the peer, returning immediately.
Begins consuming inbound envelopes from the peer, returning immediately.
Implements
|
#
|
public
|
send(JsonRpcMessage $message, ?SendContext $context = null): void
$context is accepted for TransportInterface conformance and dropped, its relatedRequestId having
no in-process equivalent.
$context is accepted for TransportInterface conformance and dropped, its relatedRequestId having
no in-process equivalent.
Throws
Implements
|
#
|
public
|
close(): void
Closes the connection once, firing onClose() after the underlying streams close, which an
implementation MUST also do after a fatal error since Server::run() blocks on that signal.
A call from another fiber while a close is in progress MUST block until that close settles,
while one re-entering from the closing fiber returns immediately.
Closes the connection once, firing onClose() after the underlying streams close, which an
implementation MUST also do after a fatal error since Server::run() blocks on that signal.
A call from another fiber while a close is in progress MUST block until that close settles,
while one re-entering from the closing fiber returns immediately.
Implements
|
#
|
public
|
onMessage(Closure $listener): ListenerHandleInterface
A transport multiplexing several peers MUST namespace or rewrite inbound request ids before
emitting them, since the protocol layer correlates and cancels by id alone.
A transport multiplexing several peers MUST namespace or rewrite inbound request ids before
emitting them, since the protocol layer correlates and cancels by id alone.
Implements
|
#
|
public
|
onError(Closure $listener): ListenerHandleInterface
An in-memory transport has no I/O failure surface, so the error listeners see only faults thrown
by this side's own message listeners.
An in-memory transport has no I/O failure surface, so the error listeners see only faults thrown
by this side's own message listeners.
Implements
|
#
|
public
|
onDrain(Closure $listener): ListenerHandleInterface
Register a drain listener that fires before close().
Register a drain listener that fires before close().
Implements
|
#
|
public
|
onClose(Closure $listener): ListenerHandleInterface
|
#
|