QudsServer class

Define the server app

Constructors

QudsServer({required String appName, required ServerConfigurations configurations, required List<QudsRouter<QudsController>> routers, List<QudsMiddleware>? middlewares, Future validateUserWebSocket(WebSocketChannel ws, Map<String, String> initialHeaders)?, List<CliCommand>? cliCommands})
Create an instance of QudsServer

Properties

appName String
The app name.
final
cliCommands List<CliCommand>?
final
configurations ServerConfigurations
The server configurations
final
hashCode int
The hash code for this object.
no setterinherited
middlewares List<QudsMiddleware>?
The injected middlewares
final
routers List<QudsRouter<QudsController>>
The server routers
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
tokenService TokenService?
To get the token service of this server app
no setter
validateUserWebSocket → (Future Function(WebSocketChannel ws, Map<String, String> initialHeaders)?)
final

Methods

handleCliCommands(Map<String, CliCommand> commands) Future<void>
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
start() Future<HttpServer>
To start the server app
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited