Package io.flutter.app

## Class FlutterPluginRegistry

- java.lang.Object
- - io.flutter.app.FlutterPluginRegistry

- All Implemented Interfaces:
    `PluginRegistry`, `PluginRegistry.ActivityResultListener`, `PluginRegistry.NewIntentListener`, `PluginRegistry.RequestPermissionsResultListener`, `PluginRegistry.UserLeaveHintListener`, `PluginRegistry.ViewDestroyListener`, `PluginRegistry.WindowFocusChangedListener`

      @Deprecated
      public class FlutterPluginRegistry
      extends Object
      implements PluginRegistry, PluginRegistry.RequestPermissionsResultListener, PluginRegistry.ActivityResultListener, PluginRegistry.NewIntentListener, PluginRegistry.WindowFocusChangedListener, PluginRegistry.UserLeaveHintListener, PluginRegistry.ViewDestroyListener

  Deprecated.
  See https://flutter.dev/go/android-project-migration for migration instructions.

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from interface io.flutter.plugin.common.PluginRegistry

      `PluginRegistry.ActivityResultListener, PluginRegistry.NewIntentListener, PluginRegistry.PluginRegistrantCallback, PluginRegistry.Registrar, PluginRegistry.RequestPermissionsResultListener, PluginRegistry.UserLeaveHintListener, PluginRegistry.ViewDestroyListener, PluginRegistry.WindowFocusChangedListener`

  - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `FlutterPluginRegistry​(FlutterEngine engine, Context context)` | Deprecated.
    `FlutterPluginRegistry​(FlutterNativeView nativeView, Context context)` | Deprecated.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods Deprecated Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `void` | `attach​(FlutterView flutterView, Activity activity)` | Deprecated.
    `void` | `destroy()` | Deprecated.
    `void` | `detach()` | Deprecated.
    `PlatformViewsController` | `getPlatformViewsController()` | Deprecated.
    `boolean` | `hasPlugin​(String key)` | Deprecated. Returns whether the specified plugin is known to this registry.
    `boolean` | `onActivityResult​(int requestCode, int resultCode, Intent data)` | Deprecated.
    `boolean` | `onNewIntent​(Intent intent)` | Deprecated.
    `void` | `onPreEngineRestart()` | Deprecated.
    `boolean` | `onRequestPermissionsResult​(int requestCode, String[] permissions, int[] grantResults)` | Deprecated.
    `void` | `onUserLeaveHint()` | Deprecated.
    `boolean` | `onViewDestroy​(FlutterNativeView view)` | Deprecated.
    `void` | `onWindowFocusChanged​(boolean hasFocus)` | Deprecated.
    `PluginRegistry.Registrar` | `registrarFor​(String pluginKey)` | Deprecated. Returns a `PluginRegistry.Registrar` for receiving the registrations pertaining to the specified plugin.
    `<T> T` | `valuePublishedByPlugin​(String pluginKey)` | Deprecated. Returns the value published by the specified plugin, if any.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### FlutterPluginRegistry

          public FlutterPluginRegistry​(FlutterNativeView nativeView,
                                       Context context)

      Deprecated.

    - #### FlutterPluginRegistry

          public FlutterPluginRegistry​(FlutterEngine engine,
                                       Context context)

      Deprecated.

  - ### Method Detail

    - #### hasPlugin

          public boolean hasPlugin​(String key)

      Deprecated.
      Description copied from interface: `PluginRegistry`
      Returns whether the specified plugin is known to this registry.
      Specified by:
        `hasPlugin` in interface `PluginRegistry`
      Parameters:
        `key` - a unique String identifying the plugin; typically the fully qualified name of the plugin's main class.
      Returns:
        true if this registry has handed out a registrar for the specified plugin.

    - #### valuePublishedByPlugin

          public <T> T valuePublishedByPlugin​(String pluginKey)

      Deprecated.
      Description copied from interface: `PluginRegistry`
      Returns the value published by the specified plugin, if any.

      Plugins may publish a single value, such as an instance of the plugin's main class, for situations where external control or interaction is needed. Clients are expected to know the value's type.

      Specified by:
        `valuePublishedByPlugin` in interface `PluginRegistry`
      Type Parameters:
        `T` - The type of the value.
      Parameters:
        `pluginKey` - a unique String identifying the plugin; typically the fully qualified name of the plugin's main class.
      Returns:
        the published value, possibly null.

    - #### registrarFor

          public PluginRegistry.Registrar registrarFor​(String pluginKey)

      Deprecated.
      Description copied from interface: `PluginRegistry`
      Returns a `PluginRegistry.Registrar` for receiving the registrations pertaining to the specified plugin.
      Specified by:
        `registrarFor` in interface `PluginRegistry`
      Parameters:
        `pluginKey` - a unique String identifying the plugin; typically the fully qualified name of the plugin's main class.
      Returns:
        A `PluginRegistry.Registrar` for receiving the registrations pertianing to the specified plugin.

    - #### attach

          public void attach​(FlutterView flutterView,
                             Activity activity)

      Deprecated.

    - #### detach

          public void detach()

      Deprecated.

    - #### onPreEngineRestart

          public void onPreEngineRestart()

      Deprecated.

    - #### getPlatformViewsController

          public PlatformViewsController getPlatformViewsController()

      Deprecated.

    - #### onRequestPermissionsResult

          public boolean onRequestPermissionsResult​(int requestCode,
                                                    String[] permissions,
                                                    int[] grantResults)

      Deprecated.
      Specified by:
        `onRequestPermissionsResult` in interface `PluginRegistry.RequestPermissionsResultListener`
      Parameters:
        `requestCode` - The request code passed in `ActivityCompat.requestPermissions(android.app.Activity, String[], int)`.
        `permissions` - The requested permissions.
        `grantResults` - The grant results for the corresponding permissions which is either `PackageManager.PERMISSION_GRANTED` or `PackageManager.PERMISSION_DENIED`.
      Returns:
        true if the result has been handled.

    - #### onActivityResult

          public boolean onActivityResult​(int requestCode,
                                          int resultCode,
                                          Intent data)

      Deprecated.
      Specified by:
        `onActivityResult` in interface `PluginRegistry.ActivityResultListener`
      Parameters:
        `requestCode` - The integer request code originally supplied to `startActivityForResult()`, allowing you to identify who this result came from.
        `resultCode` - The integer result code returned by the child activity through its `setResult()`.
        `data` - An Intent, which can return result data to the caller (various data can be attached to Intent "extras").
      Returns:
        true if the result has been handled.

    - #### onNewIntent

          public boolean onNewIntent​(Intent intent)

      Deprecated.
      Specified by:
        `onNewIntent` in interface `PluginRegistry.NewIntentListener`
      Parameters:
        `intent` - The new intent that was started for the activity.
      Returns:
        true if the new intent has been handled.

    - #### onUserLeaveHint

          public void onUserLeaveHint()

      Deprecated.
      Specified by:
        `onUserLeaveHint` in interface `PluginRegistry.UserLeaveHintListener`

    - #### onWindowFocusChanged

          public void onWindowFocusChanged​(boolean hasFocus)

      Deprecated.
      Specified by:
        `onWindowFocusChanged` in interface `PluginRegistry.WindowFocusChangedListener`

    - #### onViewDestroy

          public boolean onViewDestroy​(FlutterNativeView view)

      Deprecated.
      Specified by:
        `onViewDestroy` in interface `PluginRegistry.ViewDestroyListener`

    - #### destroy

          public void destroy()

      Deprecated.