convert method

  1. @override
Map<String, dynamic> convert(
  1. Uint8List input
)
override

Converts input and returns the result of the conversion.

Implementation

@override
Map<String, dynamic> convert(Uint8List input) {
  _input = InputStream(ByteData.sublistView(input));

  // check signature
  final signature = _input.readUint32();
  if (signature != Signature) {
    throw Exception('This is NOT a valid ggpack file :(');
  }
  numKeys = _input.readUint32();
  _offsets = _readPlo(_input);

  _input = InputStream(ByteData.sublistView(input, 12));

  return _readHash();
}