16 lines
722 B
Dart
16 lines
722 B
Dart
import 'inbound_gateway.dart';
|
|
|
|
/// Web fallback for [IsolateInboundGateway].
|
|
///
|
|
/// Worker isolates (`dart:isolate` spawn) are unavailable on web targets, so
|
|
/// this stub decodes synchronously in-process via [SyncInboundGateway] while
|
|
/// preserving the same `seq`-ordered [InboundGateway] contract. This keeps the
|
|
/// `dart.library.html` conditional export building without pulling `dart:io`
|
|
/// or `dart:isolate` into the web bundle.
|
|
///
|
|
/// Accepts (and ignores) [capacity] so the conditional-export constructor
|
|
/// signature matches the IO isolate gateway; in-process decode has no worker
|
|
/// mailbox to bound.
|
|
class IsolateInboundGateway extends SyncInboundGateway {
|
|
IsolateInboundGateway({int capacity = 0});
|
|
}
|