IdeBridgeServer class

IDE Bridge server — listens for incoming IDE extension connections.

Runs a local WebSocket server on a configurable port or Unix socket. Multiple IDE connections can be active simultaneously.

Constructors

IdeBridgeServer({int port = 19836, String host = 'localhost'})

Properties

connectionCount int
Number of active connections.
no setter
connections Iterable<IdeBridge>
All active connections.
no setter
connectUrl String
The URL clients should connect to.
no setter
firstConnected IdeBridge?
Get the first connected bridge, if any.
no setter
hashCode int
The hash code for this object.
no setterinherited
host String
final
onConnection Stream<IdeBridge>
Stream of new connections.
no setter
onMessage ↔ void Function(IdeBridge bridge, BridgeMessage message)?
Handler for incoming messages that aren't correlated responses.
getter/setter pair
port int
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

broadcast(BridgeMessage message) → void
Send a message to all connected IDEs.
findById(String connectionId) IdeBridge?
Find a connection by connection ID.
findByIdeType(IdeType type) IdeBridge?
Find a connection by IDE type.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
start() Future<void>
Start listening for IDE connections.
stop() Future<void>
Stop the server and disconnect all clients.
toString() String
A string representation of this object.
inherited

Operators

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