Flutter Linux Embedder
fl_standard_method_codec.h File Reference
#include <gmodule.h>
#include "fl_method_codec.h"
#include "fl_standard_message_codec.h"

Go to the source code of this file.

Functions

G_BEGIN_DECLS G_MODULE_EXPORT G_DECLARE_FINAL_TYPE (FlStandardMethodCodec, fl_standard_method_codec, FL, STANDARD_METHOD_CODEC, FlMethodCodec) FlStandardMethodCodec *fl_standard_method_codec_new()
 
FlStandardMethodCodec * fl_standard_method_codec_new_with_message_codec (FlStandardMessageCodec *message_codec)
 

Function Documentation

◆ fl_standard_method_codec_new_with_message_codec()

FlStandardMethodCodec* fl_standard_method_codec_new_with_message_codec ( FlStandardMessageCodec *  message_codec)

fl_standard_method_codec_new: @message_codec: A #FlMessageCodec.

Creates an #FlStandardMethodCodec with a custom message codec.

Returns: a new #FlStandardMethodCodec.

Definition at line 298 of file fl_standard_method_codec.cc.

299  {
300  return FL_STANDARD_METHOD_CODEC(
301  g_object_new(fl_standard_method_codec_get_type(), "message-codec",
302  message_codec, nullptr));
303 }

Referenced by fl_standard_method_codec_new(), and TEST().

◆ G_DECLARE_FINAL_TYPE()

G_BEGIN_DECLS G_MODULE_EXPORT G_DECLARE_FINAL_TYPE ( FlStandardMethodCodec  ,
fl_standard_method_codec  ,
FL  ,
STANDARD_METHOD_CODEC  ,
FlMethodCodec   
)

FlStandardMethodCodec:

#FlStandardMethodCodec is an #FlMethodCodec that implements method calls using the Flutter standard message encoding. It should be used with a #FlMethodChannel.

#FlStandardMethodCodec matches the StandardMethodCodec class in the Flutter services library. fl_standard_method_codec_new:

Creates an #FlStandardMethodCodec.

Returns: a new #FlStandardMethodCodec.