deconstructPacket static method

Map deconstructPacket(
  1. Map packet
)

Implementation

static Map deconstructPacket(Map packet) {
  List buffers = [];

  packet['data'] = _deconstructPacket(packet['data'], buffers);
  packet['attachments'] = buffers.length;

  final result = {'packet': packet, 'buffers': buffers};
  return result;
}