WebSocketTerminalBackend constructor
WebSocketTerminalBackend(
- WebSocket socket, {
- TerminalDimensions initialSize = (width: 80, height: 24),
- bool supportsAnsi = true,
- bool isTerminal = true,
- ColorProfile colorProfile = ColorProfile.trueColor,
- ({bool useBackspace, bool useTabs}) movementCaps = (useTabs: false, useBackspace: true),
- bool closeSocketOnDispose = true,
Creates a websocket-backed backend.
Implementation
WebSocketTerminalBackend(
this.socket, {
TerminalDimensions initialSize = const (width: 80, height: 24),
bool supportsAnsi = true,
bool isTerminal = true,
ColorProfile colorProfile = ColorProfile.trueColor,
({bool useTabs, bool useBackspace}) movementCaps = const (
useTabs: false,
useBackspace: true,
),
this.closeSocketOnDispose = true,
}) : _delegate = JsonTerminalBackend(
sendMessage: socket.add,
inboundMessages: socket,
closeTransport: closeSocketOnDispose ? () => socket.close() : null,
initialSize: initialSize,
supportsAnsi: supportsAnsi,
isTerminal: isTerminal,
colorProfile: colorProfile,
movementCaps: movementCaps,
);