SwiftNativeVisionPlugin.swift 522 B

1234567891011121314
  1. import Flutter
  2. import UIKit
  3. public class SwiftNativeVisionPlugin: NSObject, FlutterPlugin {
  4. public static func register(with registrar: FlutterPluginRegistrar) {
  5. let channel = FlutterMethodChannel(name: "native_vision", binaryMessenger: registrar.messenger())
  6. let instance = SwiftNativeVisionPlugin()
  7. registrar.addMethodCallDelegate(instance, channel: channel)
  8. }
  9. public func handle(_ call: FlutterMethodCall, result: @escaping FlutterResult) {
  10. result("iOS " + UIDevice.current.systemVersion)
  11. }
  12. }