Flutter Engine
The Flutter Engine
Public Types | Public Member Functions | List of all members
flutter::EmbedderPlatformMessageResponse Class Reference

The platform message response subclass for responses to messages from the embedder to the framework. Message responses are fulfilled by the framework. More...

#include <embedder_platform_message_response.h>

Inheritance diagram for flutter::EmbedderPlatformMessageResponse:
flutter::PlatformMessageResponse fml::RefCountedThreadSafe< PlatformMessageResponse > fml::internal::RefCountedThreadSafeBase

Public Types

using Callback = std::function< void(const uint8_t *data, size_t size)>
 

Public Member Functions

 EmbedderPlatformMessageResponse (fml::RefPtr< fml::TaskRunner > runner, const Callback &callback)
 
 ~EmbedderPlatformMessageResponse () override
 Destroys the message response. Can be called on any thread. Does not execute unfulfilled callbacks. More...
 
- Public Member Functions inherited from flutter::PlatformMessageResponse
virtual void Complete (std::unique_ptr< fml::Mapping > data)=0
 
virtual void CompleteEmpty ()=0
 
bool is_complete () const
 
- Public Member Functions inherited from fml::RefCountedThreadSafe< PlatformMessageResponse >
void Release () const
 
- Public Member Functions inherited from fml::internal::RefCountedThreadSafeBase
void AddRef () const
 
bool HasOneRef () const
 
void AssertHasOneRef () const
 

Additional Inherited Members

- Protected Member Functions inherited from flutter::PlatformMessageResponse
 PlatformMessageResponse ()
 
virtual ~PlatformMessageResponse ()
 
- Protected Member Functions inherited from fml::RefCountedThreadSafe< PlatformMessageResponse >
 RefCountedThreadSafe ()
 
 ~RefCountedThreadSafe ()
 
- Protected Member Functions inherited from fml::internal::RefCountedThreadSafeBase
 RefCountedThreadSafeBase ()
 
 ~RefCountedThreadSafeBase ()
 
bool Release () const
 
void Adopt ()
 
- Protected Attributes inherited from flutter::PlatformMessageResponse
bool is_complete_ = false
 

Detailed Description

The platform message response subclass for responses to messages from the embedder to the framework. Message responses are fulfilled by the framework.

Definition at line 18 of file embedder_platform_message_response.h.

Member Typedef Documentation

◆ Callback

Definition at line 20 of file embedder_platform_message_response.h.

Constructor & Destructor Documentation

◆ EmbedderPlatformMessageResponse()

flutter::EmbedderPlatformMessageResponse::EmbedderPlatformMessageResponse ( fml::RefPtr< fml::TaskRunner runner,
const Callback callback 
)
Parameters
[in]runnerThe task runner on which to execute the callback. The response will be initiated by the framework on the UI thread.
[in]callbackThe callback that communicates to the embedder the contents of the response sent by the framework back to the emebder.

Definition at line 11 of file embedder_platform_message_response.cc.

14 : runner_(std::move(runner)), callback_(callback) {}
FlKeyEvent uint64_t FlKeyResponderAsyncCallback callback

◆ ~EmbedderPlatformMessageResponse()

flutter::EmbedderPlatformMessageResponse::~EmbedderPlatformMessageResponse ( )
overridedefault

Destroys the message response. Can be called on any thread. Does not execute unfulfilled callbacks.


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