Go to the source code of this file.
Functions | |
G_BEGIN_DECLS void | fl_standard_message_codec_write_size (FlStandardMessageCodec *codec, GByteArray *buffer, uint32_t size) |
gboolean | fl_standard_message_codec_read_size (FlStandardMessageCodec *codec, GBytes *buffer, size_t *offset, uint32_t *value, GError **error) |
gboolean | fl_standard_message_codec_write_value (FlStandardMessageCodec *codec, GByteArray *buffer, FlValue *value, GError **error) |
FlValue * | fl_standard_message_codec_read_value (FlStandardMessageCodec *codec, GBytes *buffer, size_t *offset, GError **error) |
gboolean fl_standard_message_codec_read_size | ( | FlStandardMessageCodec * | codec, |
GBytes * | buffer, | ||
size_t * | offset, | ||
uint32_t * | value, | ||
GError ** | error | ||
) |
fl_standard_message_codec_read_size: @codec: an #FlStandardMessageCodec. @buffer: buffer to read from. @offset: (inout): read position in @buffer. @value: location to read size. @error: (allow-none): #GError location to store the error occurring, or NULL.
Reads a size field in Flutter Standard encoding.
Returns: TRUE on success.
Definition at line 477 of file fl_standard_message_codec.cc.
References buffer, error, read_uint16(), read_uint32(), read_uint8(), TRUE, and value.
Referenced by read_float32_list_value(), read_float64_list_value(), read_int32_list_value(), read_int64_list_value(), read_list_value(), read_map_value(), read_string_value(), and read_uint8_list_value().
FlValue* fl_standard_message_codec_read_value | ( | FlStandardMessageCodec * | codec, |
GBytes * | buffer, | ||
size_t * | offset, | ||
GError ** | error | ||
) |
fl_standard_message_codec_read_value: @codec: an #FlStandardMessageCodec. @buffer: buffer to read from. @offset: (inout): read position in @buffer. @value: location to read size. @error: (allow-none): #GError location to store the error occurring, or NULL.
Reads an FlValue in Flutter Standard encoding.
Returns: a new FlValue or NULL on error.
Definition at line 633 of file fl_standard_message_codec.cc.
References buffer, error, FL_MESSAGE_CODEC_ERROR, FL_MESSAGE_CODEC_ERROR_UNSUPPORTED_TYPE, fl_value_new_bool(), fl_value_new_null(), fl_value_ref(), kValueFalse, kValueFloat32List, kValueFloat64, kValueFloat64List, kValueInt32, kValueInt32List, kValueInt64, kValueInt64List, kValueList, kValueMap, kValueNull, kValueString, kValueTrue, kValueUint8List, read_float32_list_value(), read_float64_list_value(), read_float64_value(), read_int32_list_value(), read_int32_value(), read_int64_list_value(), read_int64_value(), read_list_value(), read_map_value(), read_string_value(), read_uint8(), read_uint8_list_value(), TRUE, and value.
Referenced by fl_standard_message_codec_decode_message(), fl_standard_method_codec_decode_method_call(), fl_standard_method_codec_decode_response(), read_list_value(), and read_map_value().
G_BEGIN_DECLS void fl_standard_message_codec_write_size | ( | FlStandardMessageCodec * | codec, |
GByteArray * | buffer, | ||
uint32_t | size | ||
) |
fl_standard_message_codec_write_size: @codec: an #FlStandardMessageCodec. @buffer: buffer to write into. @size: size value to write.
Writes a size field in Flutter Standard encoding.
Definition at line 463 of file fl_standard_message_codec.cc.
References buffer, write_uint16(), and write_uint32().
Referenced by fl_standard_message_codec_write_value().
gboolean fl_standard_message_codec_write_value | ( | FlStandardMessageCodec * | codec, |
GByteArray * | buffer, | ||
FlValue * | value, | ||
GError ** | error | ||
) |
fl_standard_message_codec_write_value: @codec: an #FlStandardMessageCodec. @buffer: buffer to write into. @value: (allow-none): value to write. @error: (allow-none): #GError location to store the error occurring, or NULL.
Writes an FlValue in Flutter Standard encoding.
Returns: TRUE on success.
Definition at line 504 of file fl_standard_message_codec.cc.
References buffer, error, FL_MESSAGE_CODEC_ERROR, FL_MESSAGE_CODEC_ERROR_UNSUPPORTED_TYPE, fl_standard_message_codec_write_size(), fl_standard_message_codec_write_value(), fl_value_get_bool(), fl_value_get_float(), fl_value_get_float32_list(), fl_value_get_float_list(), fl_value_get_int(), fl_value_get_int32_list(), fl_value_get_int64_list(), fl_value_get_length(), fl_value_get_list_value(), fl_value_get_map_key(), fl_value_get_map_value(), fl_value_get_string(), fl_value_get_type(), fl_value_get_uint8_list(), FL_VALUE_TYPE_BOOL, FL_VALUE_TYPE_FLOAT, FL_VALUE_TYPE_FLOAT32_LIST, FL_VALUE_TYPE_FLOAT_LIST, FL_VALUE_TYPE_INT, FL_VALUE_TYPE_INT32_LIST, FL_VALUE_TYPE_INT64_LIST, FL_VALUE_TYPE_LIST, FL_VALUE_TYPE_MAP, FL_VALUE_TYPE_NULL, FL_VALUE_TYPE_STRING, FL_VALUE_TYPE_UINT8_LIST, kValueFalse, kValueFloat32List, kValueFloat64, kValueFloat64List, kValueInt32, kValueInt32List, kValueInt64, kValueInt64List, kValueList, kValueMap, kValueNull, kValueString, kValueTrue, kValueUint8List, TRUE, value, write_align(), write_float64(), write_int32(), and write_int64().
Referenced by fl_standard_message_codec_encode_message(), fl_standard_message_codec_write_value(), fl_standard_method_codec_encode_error_envelope(), fl_standard_method_codec_encode_method_call(), and fl_standard_method_codec_encode_success_envelope().