Codec class
Frame codec for gRPC over WebRTC DataChannels (wire protocol in ../SPEC.md). Frame, status, channel and server semantics mirror the other grpcdc runtimes; the tables in wire.dart are stamped by the grpc-dc codegen.
Constructors
- Codec()
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
decodeFrame(
Uint8List data) → ({Uint8List payload, int streamId, int type}) - One parsed frame.
-
encodeFrame(
int frameType, int streamId, List< int> payload) → Uint8List - Build one DataChannel message: header + payload.
-
encodeTimeout(
Duration timeout) → String - gRPC timeout grammar (grpc-timeout metadata):
-
getU32(
Uint8List input, int offset) → int -
headersFrame(
int streamId, String? path, Map< String, String> ? metadata) → Uint8List -
parseHeaders(
List< int> payload) → Headers -
parseStatus(
List< int> payload) → StatusException -
parseTimeout(
String? text) → Duration? - Decoded grpc-timeout, or null when malformed/absent.
-
putU32(
Uint8List out, int offset, int value) → void -
statusFrame(
int frameType, int streamId, StatusException status) → Uint8List
Constants
- headerLen → const int
- maxDataPayload → const int