Flutter Engine
flutter::PlatformMessage Class Reference

#include <platform_message.h>

Public Member Functions

 PlatformMessage (std::string channel, fml::MallocMapping data, fml::RefPtr< PlatformMessageResponse > response)
 
 PlatformMessage (std::string channel, fml::RefPtr< PlatformMessageResponse > response)
 
 ~PlatformMessage ()
 
const std::string & channel () const
 
const fml::MallocMappingdata () const
 
bool hasData ()
 
const fml::RefPtr< PlatformMessageResponse > & response () const
 
fml::MallocMapping releaseData ()
 

Detailed Description

Definition at line 17 of file platform_message.h.

Constructor & Destructor Documentation

◆ PlatformMessage() [1/2]

flutter::PlatformMessage::PlatformMessage ( std::string  channel,
fml::MallocMapping  data,
fml::RefPtr< PlatformMessageResponse response 
)

Definition at line 11 of file platform_message.cc.

14  : channel_(std::move(channel)),
15  data_(std::move(data)),
16  hasData_(true),
17  response_(std::move(response)) {}
const std::string & channel() const

◆ PlatformMessage() [2/2]

flutter::PlatformMessage::PlatformMessage ( std::string  channel,
fml::RefPtr< PlatformMessageResponse response 
)

Definition at line 18 of file platform_message.cc.

References ~PlatformMessage().

20  : channel_(std::move(channel)),
21  data_(),
22  hasData_(false),
23  response_(std::move(response)) {}
const std::string & channel() const

◆ ~PlatformMessage()

flutter::PlatformMessage::~PlatformMessage ( )
default

Referenced by PlatformMessage().

Member Function Documentation

◆ channel()

const std::string& flutter::PlatformMessage::channel ( ) const
inline

Definition at line 26 of file platform_message.h.

26 { return channel_; }

◆ data()

const fml::MallocMapping& flutter::PlatformMessage::data ( ) const
inline

Definition at line 27 of file platform_message.h.

Referenced by flutter::Engine::DispatchPlatformMessage(), and flutter_runner::testing::TEST_F().

27 { return data_; }

◆ hasData()

bool flutter::PlatformMessage::hasData ( )
inline

Definition at line 28 of file platform_message.h.

28 { return hasData_; }

◆ releaseData()

fml::MallocMapping flutter::PlatformMessage::releaseData ( )
inline

Definition at line 34 of file platform_message.h.

34 { return std::move(data_); }

◆ response()

const fml::RefPtr<PlatformMessageResponse>& flutter::PlatformMessage::response ( ) const
inline

Definition at line 30 of file platform_message.h.

30  {
31  return response_;
32  }

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