ServerFactory
class ServerFactory
Properties
| protected LoggerInterface|null | $logger | ||
| protected Dispatcher|null | $eventDispatcher | ||
| protected ServerInterface|null | $server | ||
| protected ServerConfig|null | $config |
Methods
Configure the server with the given config array.
Start the server.
Get the server instance.
Get the event dispatcher instance.
Get the logger instance.
Set the logger instance.
Get the server configuration.
Details
at line 24
__construct(Container $container)
No description
at line 31
void
configure(array $config)
Configure the server with the given config array.
at line 41
void
start()
Start the server.
at line 49
ServerInterface
getServer()
Get the server instance.
at line 68
ServerFactory
setServer(ServerInterface $server)
Set the server instance.
Mutates the shared ServerFactory before startup; runtime use races across coroutines and changes the server used by later calls.
at line 78
Dispatcher
getEventDispatcher()
Get the event dispatcher instance.
at line 92
ServerFactory
setEventDispatcher(Dispatcher $eventDispatcher)
Set the event dispatcher instance.
Set before configure(); the constructed Server captures this dispatcher and does not pick up later changes.
at line 102
LoggerInterface
getLogger()
Get the logger instance.
at line 116
ServerFactory
setLogger(LoggerInterface $logger)
Set the logger instance.
Set before configure(); the constructed Server captures this logger and does not pick up later changes.
at line 126
ServerConfig|null
getConfig()
Get the server configuration.