getSingleResource method

Future<Resource?> getSingleResource(
  1. ResourceType type,
  2. String id
)

Implementation

Future<Resource?> getSingleResource(ResourceType type, String id) async {
  // bool shouldFallbackToDefaultLanguage
  Map<String, dynamic> args = <String, dynamic>{};
  args.putIfAbsent("type", () => type.index);
  args.putIfAbsent("id", () => id);
  // args.putIfAbsent("should_fallback_to_default_language",
  //     () => shouldFallbackToDefaultLanguage);
  return _getResource(await _channel.invokeMethod('getSingleResource', args));
}