else

result

FlutterMethodNotImplemented

return

self

receiveBatteryLevel

result

result

})

Start by opening the iOS host portion of the Flutter app in Xcode:

Start Xcode.

Select the menu item File > Open….

Navigate to the directory holding your Flutter app,
and select the ios folder inside it. Click OK.

Make sure the Xcode projects builds without errors.

Open the file AppDelegate.m, located under Runner > Runner
in the Project navigator.

Create a FlutterMethodChannel and add a handler inside the application
didFinishLaunchingWithOptions: method.
Make sure to use the same channel name
as was used on the Flutter client side.

#import <Flutter/Flutter.h>
#import "GeneratedPluginRegistrant.h"