IpcHub
extends
Closable
in
Table of Contents
Methods
- accept() : Socket
- close() : void
- Closes the resource, marking it as unusable.
- generateKey() : non-empty-string
- getUri() : non-empty-string
- isClosed() : bool
- Returns whether this resource has been closed.
- onClose() : void
- Registers a callback that is invoked when this resource is closed.
Methods
accept()
public
accept(non-empty-string $key[, Cancellation|null $cancellation = null ]) : Socket
Parameters
- $key : non-empty-string
-
A key generated by generateKey().
- $cancellation : Cancellation|null = null
Return values
Socketclose()
Closes the resource, marking it as unusable.
public
close() : void
Whether pending operations are aborted or not is implementation dependent.
generateKey()
public
generateKey() : non-empty-string
Return values
non-empty-string —Pass the key returned from this method to the connecting context and accept().
getUri()
public
getUri() : non-empty-string
Return values
non-empty-string —URI to use with connect().
isClosed()
Returns whether this resource has been closed.
public
isClosed() : bool
Return values
bool —true if closed, otherwise false.
onClose()
Registers a callback that is invoked when this resource is closed.
public
onClose(callable(): void $onClose) : void
Parameters
- $onClose : callable(): void