getCountryFlagByIndex static method
- required int index,
- Size? size,
- ImageFileFormat? format,
Returns the country flag image bytes for the specified country index.
Parameters
index: (int) Internal country index.size: (Size?) Optional desired image size. If omitted the image's natural size is returned.format: (ImageFileFormat?) Optional image format.
Returns
- (
Uint8List?) Raw image bytes for the flag, or null if unavailable.
Also see:
- getCountryFlagImgByIndex - Retrieve an Img wrapper for the flag.
- getCountryFlag - Retrieve flag image bytes by ISO code.
Implementation
static Uint8List? getCountryFlagByIndex({
required final int index,
final Size? size,
final ImageFileFormat? format,
}) {
return GemKitPlatform.instance.callGetImage(
0,
'MapDetailsgetCountryIcon',
size?.width.toInt() ?? -1,
size?.height.toInt() ?? -1,
format?.id ?? -1,
arg: index.toString(),
);
}