loadLabelsFromAsset method
Load label names from a text file in Android assets. File format: one label name per line. Returns the list of labels loaded.
Implementation
Future<List<String>> loadLabelsFromAsset(String fileName) async {
final result = await _methodChannel.invokeMapMethod<String, dynamic>('loadLabelsFromAsset', {'fileName': fileName});
return (result?['labels'] as List?)?.cast<String>() ?? [];
}