setSource static method

Future<void> setSource(
  1. String resource,
  2. String platform,
  3. String language
)

Implementation

static Future<void> setSource(String resource, String platform, String language) async{
  try{
    final arguments = {
      "resource": resource,
      "platform": platform,
      "language": language
    };
    final result = await channel.invokeMethod('setSource', arguments);
    debugPrint("result is $result");
  } on PlatformException catch (e) {
    debugPrint("Error: $e");
  } catch (e) {
    debugPrint("Error: $e");
  }
}