Flutter Engine
The Flutter Engine
Classes | Public Member Functions | List of all members
io.flutter.embedding.engine.systemchannels.PlatformViewsChannel Class Reference

Classes

interface  PlatformViewBufferResized
 
class  PlatformViewBufferSize
 
class  PlatformViewCreationRequest
 
class  PlatformViewResizeRequest
 
interface  PlatformViewsHandler
 
class  PlatformViewTouch
 

Public Member Functions

void invokeViewFocused (int viewId)
 
 PlatformViewsChannel (@NonNull DartExecutor dartExecutor)
 
void setPlatformViewsHandler (@Nullable PlatformViewsHandler handler)
 

Detailed Description

System channel that sends 2-way communication between Flutter and Android to facilitate embedding of Android Views within a Flutter application.

Register a PlatformViewsHandler to implement the Android side of this channel.

Definition at line 25 of file PlatformViewsChannel.java.

Constructor & Destructor Documentation

◆ PlatformViewsChannel()

io.flutter.embedding.engine.systemchannels.PlatformViewsChannel.PlatformViewsChannel ( @NonNull DartExecutor  dartExecutor)
inline

Constructs a PlatformViewsChannel that connects Android to the Dart code running in dartExecutor.

The given dartExecutor is permitted to be idle or executing code.

See DartExecutor.

Definition at line 267 of file PlatformViewsChannel.java.

267 {
268 channel =
269 new MethodChannel(dartExecutor, "flutter/platform_views", StandardMethodCodec.INSTANCE);
270 channel.setMethodCallHandler(parsingHandler);
271 }
void setMethodCallHandler(final @Nullable MethodCallHandler handler)

Member Function Documentation

◆ invokeViewFocused()

void io.flutter.embedding.engine.systemchannels.PlatformViewsChannel.invokeViewFocused ( int  viewId)
inline

Definition at line 31 of file PlatformViewsChannel.java.

31 {
32 if (channel == null) {
33 return;
34 }
35 channel.invokeMethod("viewFocused", viewId);
36 }
void invokeMethod(@NonNull String method, @Nullable Object arguments)

◆ setPlatformViewsHandler()

void io.flutter.embedding.engine.systemchannels.PlatformViewsChannel.setPlatformViewsHandler ( @Nullable PlatformViewsHandler  handler)
inline

Sets the PlatformViewsHandler which receives all events and requests that are parsed from the underlying platform views channel.

Definition at line 277 of file PlatformViewsChannel.java.

277 {
278 this.handler = handler;
279 }

The documentation for this class was generated from the following file: