# Type Definitions

The following type definitions are available globally.

- `FlutterBinaryReply`

  A message reply callback.

  Used for submitting a binary reply back to a Flutter message sender. Also used in for handling a binary message reply received from Flutter.

  #### Declaration

  Objective-C

      typedef void (^FlutterBinaryReply)(NSData *_Nullable)

  Swift

      typealias FlutterBinaryReply = (Data?) -> Void

  #### Parameters

  `reply` | The reply.

- `FlutterBinaryMessageHandler`

  A strategy for handling incoming binary messages from Flutter and to send asynchronous replies back to Flutter.

  #### Declaration

  Objective-C

      typedef void (^FlutterBinaryMessageHandler)(NSData *_Nullable,
                                                  FlutterBinaryReply _Nonnull)

  Swift

      typealias FlutterBinaryMessageHandler = (Data?, @escaping FlutterBinaryReply) -> Void

  #### Parameters

  `message` | The message.
  `reply` | A callback for submitting an asynchronous reply to the sender.

- `FlutterBinaryMessengerConnection`

  Undocumented

  #### Declaration

  Objective-C

      typedef int64_t FlutterBinaryMessengerConnection

  Swift

      typealias FlutterBinaryMessengerConnection = Int64

- `FlutterReply`

  A message reply callback.

  Used for submitting a reply back to a Flutter message sender. Also used in the dual capacity for handling a message reply received from Flutter.

  #### Declaration

  Objective-C

      typedef void (^FlutterReply)(id _Nullable)

  Swift

      typealias FlutterReply = (Any?) -> Void

  #### Parameters

  `reply` | The reply.

- `FlutterMessageHandler`

  A strategy for handling incoming messages from Flutter and to send asynchronous replies back to Flutter.

  #### Declaration

  Objective-C

      typedef void (^FlutterMessageHandler)(id _Nullable, FlutterReply _Nonnull)

  Swift

      typealias FlutterMessageHandler = (Any?, @escaping FlutterReply) -> Void

  #### Parameters

  `message` | The message.
  `callback` | A callback for submitting a reply to the sender which can be invoked from any thread.

- `FlutterResult`

  A method call result callback.

  Used for submitting a method call result back to a Flutter caller. Also used in the dual capacity for handling a method call result received from Flutter.

  #### Declaration

  Objective-C

      typedef void (^FlutterResult)(id _Nullable)

  Swift

      typealias FlutterResult = (Any?) -> Void

  #### Parameters

  `result` | The result.

- `FlutterMethodCallHandler`

  A strategy for handling method calls.

  #### Declaration

  Objective-C

      typedef void (^FlutterMethodCallHandler)(FlutterMethodCall *_Nonnull,
                                               FlutterResult _Nonnull)

  Swift

      typealias FlutterMethodCallHandler = (FlutterMethodCall, @escaping FlutterResult) -> Void

  #### Parameters

  `call` | The incoming method call.
  `result` | A callback to asynchronously submit the result of the call. Invoke the callback with a `FlutterError` to indicate that the call failed. Invoke the callback with `FlutterMethodNotImplemented` to indicate that the method was unknown. Any other values, including `nil`, are interpreted as successful results. This can be invoked from any thread.

- `FlutterEventSink`

  An event sink callback.

  #### Declaration

  Objective-C

      typedef void (^FlutterEventSink)(id _Nullable)

  Swift

      typealias FlutterEventSink = (Any?) -> Void

  #### Parameters

  `event` | The event.

- `FlutterHeadlessDartRunnerCallback`

  A callback for when FlutterHeadlessDartRunner has attempted to start a Dart Isolate in the background.

  #### Declaration

  Objective-C

      typedef void (^FlutterHeadlessDartRunnerCallback)(BOOL)

  Swift

      typealias FlutterHeadlessDartRunnerCallback = (Bool) -> Void

  #### Parameters

  `success` | YES if the Isolate was started and run successfully, NO otherwise.

- `FlutterPluginRegistrantCallback`

  A plugin registration callback.

  Used for registering plugins with additional instances of `FlutterPluginRegistry`.

  #### Declaration

  Objective-C

      typedef void (*FlutterPluginRegistrantCallback)(
          NSObject<FlutterPluginRegistry> *_Nonnull)

  Swift

      typealias FlutterPluginRegistrantCallback = (FlutterPluginRegistry) -> Void

  #### Parameters

  `registry` | The registry to register plugins with.

- `FlutterPlatformViewGestureRecognizersBlockingPolicy`

  How the UIGestureRecognizers of a platform view are blocked.

  UIGestureRecognizers of platform views can be blocked based on decisions made by the Flutter Framework (e.g. When an interact-able widget is covering the platform view).

  See more

  #### Declaration

  Objective-C

      typedef enum FlutterPlatformViewGestureRecognizersBlockingPolicy
          FlutterPlatformViewGestureRecognizersBlockingPolicy

© 2023 Flutter. All rights reserved. (Last updated: 2023-02-28)

Generated by jazzy ♪♫ v0.14.3, a Realm project.