Flutter Engine
The Flutter Engine
|
Public Member Functions | |
ProcessTextPlugin (@NonNull ProcessTextChannel processTextChannel) | |
Map< String, String > | queryTextActions () |
void | processTextAction ( @NonNull String id, @NonNull String text, @NonNull boolean readOnly, @NonNull MethodChannel.Result result) |
boolean | onActivityResult (int requestCode, int resultCode, @Nullable Intent intent) |
void | destroy () |
void | onAttachedToEngine (@NonNull FlutterPluginBinding binding) |
void | onDetachedFromEngine (@NonNull FlutterPluginBinding binding) |
void | onAttachedToActivity (@NonNull ActivityPluginBinding binding) |
void | onDetachedFromActivityForConfigChanges () |
void | onReattachedToActivityForConfigChanges (@NonNull ActivityPluginBinding binding) |
void | onDetachedFromActivity () |
void | onAttachedToEngine (@NonNull FlutterPluginBinding binding) |
void | onDetachedFromEngine (@NonNull FlutterPluginBinding binding) |
void | onAttachedToActivity (@NonNull ActivityPluginBinding binding) |
void | onDetachedFromActivityForConfigChanges () |
void | onReattachedToActivityForConfigChanges (@NonNull ActivityPluginBinding binding) |
void | onDetachedFromActivity () |
boolean | onActivityResult (int requestCode, int resultCode, @Nullable Intent data) |
Map< String, String > | queryTextActions () |
void | processTextAction ( @NonNull String id, @NonNull String input, @NonNull boolean readOnly, @NonNull MethodChannel.Result result) |
Definition at line 28 of file ProcessTextPlugin.java.
|
inline |
Definition at line 44 of file ProcessTextPlugin.java.
|
inline |
Unregisters this ProcessTextPlugin
as the
, for the
ProcessTextChannel.ProcessTextMethodHandlerio.flutter.embedding.engine.systemchannels.ProcessTextChannel
.
Do not invoke any methods on a ProcessTextPlugin
after invoking this method.
Definition at line 162 of file ProcessTextPlugin.java.
|
inline |
Executed when a text processing activity terminates.
When an activity returns a value, the request is completed successfully and returns the processed text.
When an activity does not return a value. the request is completed successfully and returns null.
Implements io.flutter.plugin.common.PluginRegistry.ActivityResultListener.
Definition at line 141 of file ProcessTextPlugin.java.
|
inline |
This ActivityAware
io.flutter.embedding.engine.plugins.FlutterPlugin
is now associated with an android.app.Activity
.
This method can be invoked in 1 of 2 situations:
ActivityAware
io.flutter.embedding.engine.plugins.FlutterPlugin
was just added to a io.flutter.embedding.engine.FlutterEngine
that was already connected to a running android.app.Activity
. ActivityAware
io.flutter.embedding.engine.plugins.FlutterPlugin
was already added to a io.flutter.embedding.engine.FlutterEngine
and that io.flutter.embedding.engine.FlutterEngine
was just connected to an android.app.Activity
. The given ActivityPluginBinding
contains android.app.Activity
-related references that an ActivityAware
io.flutter.embedding.engine.plugins.FlutterPlugin
may require, such as a reference to the actual android.app.Activity
in question. The ActivityPluginBinding
may be referenced until either onDetachedFromActivityForConfigChanges()
or onDetachedFromActivity()
is invoked. At the conclusion of either of those methods, the binding is no longer valid. Clear any references to the binding or its resources, and do not invoke any further methods on the binding or its resources.
Implements io.flutter.embedding.engine.plugins.activity.ActivityAware.
Definition at line 180 of file ProcessTextPlugin.java.
|
inline |
This FlutterPlugin
has been associated with a io.flutter.embedding.engine.FlutterEngine
instance.
Relevant resources that this FlutterPlugin
may need are provided via the
. The
bindingbinding
may be cached and referenced until onDetachedFromEngine(FlutterPluginBinding)
is invoked and returns.
Implements io.flutter.embedding.engine.plugins.FlutterPlugin.
Definition at line 168 of file ProcessTextPlugin.java.
|
inline |
This plugin has been detached from an android.app.Activity
.
Detachment can occur for a number of reasons.
android.app.Activity
instance has been destroyed. io.flutter.embedding.engine.FlutterEngine
that this plugin is connected to has been detached from its io.flutter.embedding.android.FlutterView
. ActivityAware
plugin has been removed from its io.flutter.embedding.engine.FlutterEngine
. By the end of this method, the android.app.Activity
that was made available in onAttachedToActivity(ActivityPluginBinding)
is no longer valid. Any references to the associated android.app.Activity
or ActivityPluginBinding
should be cleared.
Any Lifecycle
listeners that were registered in onAttachedToActivity(ActivityPluginBinding)
or onReattachedToActivityForConfigChanges(ActivityPluginBinding)
should be deregistered here to avoid a possible memory leak and other side effects.
Implements io.flutter.embedding.engine.plugins.activity.ActivityAware.
Definition at line 195 of file ProcessTextPlugin.java.
|
inline |
The android.app.Activity
that was attached and made available in onAttachedToActivity(ActivityPluginBinding)
has been detached from this
's
ActivityAwareio.flutter.embedding.engine.FlutterEngine
for the purpose of processing a configuration change.
By the end of this method, the android.app.Activity
that was made available in onAttachedToActivity(ActivityPluginBinding)
is no longer valid. Any references to the associated android.app.Activity
or ActivityPluginBinding
should be cleared.
This method should be quickly followed by onReattachedToActivityForConfigChanges(ActivityPluginBinding)
, which signifies that a new android.app.Activity
has been created with the new configuration options. That method provides a new ActivityPluginBinding
, which references the newly created and associated android.app.Activity
.
Any Lifecycle
listeners that were registered in onAttachedToActivity(ActivityPluginBinding)
should be deregistered here to avoid a possible memory leak and other side effects.
Implements io.flutter.embedding.engine.plugins.activity.ActivityAware.
Definition at line 185 of file ProcessTextPlugin.java.
|
inline |
This FlutterPlugin
has been removed from a io.flutter.embedding.engine.FlutterEngine
instance.
The binding
passed to this method is the same instance that was passed in onAttachedToEngine(FlutterPluginBinding)
. It is provided again in this method as a convenience. The binding
may be referenced during the execution of this method, but it must not be cached or referenced after this method returns.
FlutterPlugin
s should release all resources in this method.
Implements io.flutter.embedding.engine.plugins.FlutterPlugin.
Definition at line 172 of file ProcessTextPlugin.java.
|
inline |
This plugin and its io.flutter.embedding.engine.FlutterEngine
have been re-attached to an android.app.Activity
after the android.app.Activity
was recreated to handle configuration changes.
binding
includes a reference to the new instance of the android.app.Activity
. binding
and its references may be cached and used from now until either onDetachedFromActivityForConfigChanges()
or onDetachedFromActivity()
is invoked. At the conclusion of either of those methods, the binding is no longer valid. Clear any references to the binding or its resources, and do not invoke any further methods on the binding or its resources.
Implements io.flutter.embedding.engine.plugins.activity.ActivityAware.
Definition at line 190 of file ProcessTextPlugin.java.
|
inline |
Requests to run a text action on a given input text.
id | The ID of the text action returned by ProcessText.queryTextActions . |
input | The text to be processed. |
readOnly | Indicates to the activity if the processed text will be used as read-only. see https://developer.android.com/reference/android/content/Intent#EXTRA_PROCESS_TEXT_READONLY |
result | The method channel result instance used to reply. |
Implements io.flutter.embedding.engine.systemchannels.ProcessTextChannel.ProcessTextMethodHandler.
Definition at line 65 of file ProcessTextPlugin.java.
|
inline |
Requests the map of text actions. Each text action has a unique id and a localized label.
Implements io.flutter.embedding.engine.systemchannels.ProcessTextChannel.ProcessTextMethodHandler.
Definition at line 52 of file ProcessTextPlugin.java.