ServerIO class

a Class that represents a ServerIO.

Constructors

ServerIO({Map? options})

Properties

adapter String
getter/setter pair
encoder Encoder
getter/setter pair
engine Engine?
getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
httpServer HttpServer?
getter/setter pair
nsps Map<String, Namespace>
getter/setter pair
port int?
Server's port
no setter
ready Future<bool>
Server is ready
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
sockets Namespace
getter/setter pair

Methods

bind(Engine engine) ServerIO
checkRequest(HttpRequest req, [Function? fn]) → void
clients(dynamic _) Namespace
close() Future<void>
Closes server connection
compress(dynamic _) Namespace
emit(dynamic event, dynamic data) → void
listen(dynamic host, int port, [Map? opts]) Future<void>
Attaches socket.io to a port.
listenToHttpServer(StreamController<HttpRequest> httpServerStream, [Map? opts]) Future<void>
Attaches socket.io to a server.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
of(dynamic name, [dynamic fn]) Namespace
off(dynamic event, dynamic handler) → void
on(dynamic event, dynamic handler) → void
once(dynamic event, dynamic handler) → void
onConnection(dynamic conn) ServerIO
origins([String? v]) → dynamic
Sets the allowed origins for requests.
path([String? v]) → dynamic
Sets the client serving path.
send(dynamic _) → void
serveClient([bool? v]) → dynamic
Sets/gets whether client code is being served.
set(String key, [dynamic val]) ServerIO
Backwards compatibility.
to(dynamic _) Namespace
toString() String
A string representation of this object.
inherited
use(dynamic _) Namespace
write(dynamic _) Namespace

Operators

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