Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Instance Methods | Class Methods | List of all members
FlutterBinaryCodec Class Reference

#include <FlutterCodecs.h>

Inheritance diagram for FlutterBinaryCodec:
<FlutterMessageCodec>

Instance Methods

(NSData *) - encode: [implementation]
 
(NSData *) - decode: [implementation]
 
- Instance Methods inherited from <FlutterMessageCodec>
(NSData *_Nullable) - encode:
 
(id _Nullable) - decode:
 

Class Methods

(instancetype) + sharedInstance [implementation]
 

Detailed Description

A FlutterMessageCodec using unencoded binary messages, represented as NSData instances.

This codec is guaranteed to be compatible with the corresponding BinaryCodec on the Dart side. These parts of the Flutter SDK are evolved synchronously.

On the Dart side, messages are represented using ByteData.

Definition at line 52 of file FlutterCodecs.h.

Method Documentation

◆ decode:

- (NSData *) decode: (NSData*)  message
implementation

Definition at line 9 of file FlutterCodecs.mm.

25 :(NSData*)message {
26 return message;
27}
Win32Message message

◆ encode:

- (NSData *) encode: (id message
implementation

Definition at line 9 of file FlutterCodecs.mm.

20 :(id)message {
21 NSAssert(!message || [message isKindOfClass:[NSData class]], @"");
22 return message;
23}
const uintptr_t id

◆ sharedInstance

+ (instancetype) sharedInstance
implementation

Returns a shared instance of this FlutterMessageCodec.

Reimplemented from <FlutterMessageCodec>.

Definition at line 9 of file FlutterCodecs.mm.

12 {
13 static id _sharedInstance = nil;
14 if (!_sharedInstance) {
15 _sharedInstance = [[FlutterBinaryCodec alloc] init];
16 }
17 return _sharedInstance;
18}

The documentation for this class was generated from the following files: