callback method

void callback(
  1. IStatus status,
  2. String text
)

Implementation

void callback(IStatus status, String text) {
  final textUtf = text.toNativeUtf8(allocator: mem);
  try {
    _callback(self, status.self, textUtf);
    status.checkStatus();
  } finally {
    mem.free(textUtf);
  }
}