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

#include <platform_message_response_darwin.h>

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

Public Member Functions

void Complete (std::unique_ptr< fml::Mapping > data) override
 
void CompleteEmpty () override
 
- 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

Definition at line 21 of file platform_message_response_darwin.h.

Member Function Documentation

◆ Complete()

void flutter::PlatformMessageResponseDarwin::Complete ( std::unique_ptr< fml::Mapping data)
overridevirtual

Implements flutter::PlatformMessageResponse.

Definition at line 21 of file platform_message_response_darwin.mm.

21 {
23 platform_task_runner_->PostTask(fml::MakeCopyable([self, data = std::move(data)]() mutable {
24 self->callback_.get()(CopyMappingPtrToNSData(std::move(data)));
25 }));
26}
virtual void PostTask(const fml::closure &task) override
Definition: task_runner.cc:24
NSData * CopyMappingPtrToNSData(std::unique_ptr< fml::Mapping > mapping)
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot data
Definition: switches.h:41
internal::CopyableLambda< T > MakeCopyable(T lambda)
Definition: make_copyable.h:57

◆ CompleteEmpty()

void flutter::PlatformMessageResponseDarwin::CompleteEmpty ( )
overridevirtual

Implements flutter::PlatformMessageResponse.

Definition at line 28 of file platform_message_response_darwin.mm.

28 {
30 platform_task_runner_->PostTask(
31 fml::MakeCopyable([self]() mutable { self->callback_.get()(nil); }));
32}

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