5#include "flutter/shell/platform/linux/public/flutter_linux/fl_value.h"
113 g_string_append_printf(
buffer,
"%" G_GINT64_FORMAT,
value);
122 for (
int i =
buffer->len - 1;
i >= 0;
i--) {
125 zero_count = zero_count == 0 ? 0 : zero_count - 1;
137 switch (
value->type) {
139 g_string_append(
buffer,
"null");
143 g_string_append(
buffer,
"true");
145 g_string_append(
buffer,
"false");
159 g_string_append(
buffer,
"[");
163 g_string_append(
buffer,
", ");
167 g_string_append(
buffer,
"]");
171 g_string_append(
buffer,
"[");
175 g_string_append(
buffer,
", ");
179 g_string_append(
buffer,
"]");
183 g_string_append(
buffer,
"[");
187 g_string_append(
buffer,
", ");
191 g_string_append(
buffer,
"]");
195 g_string_append(
buffer,
"[");
199 g_string_append(
buffer,
", ");
203 g_string_append(
buffer,
"]");
207 g_string_append(
buffer,
"[");
211 g_string_append(
buffer,
", ");
215 g_string_append(
buffer,
"]");
219 g_string_append(
buffer,
"[");
222 g_string_append(
buffer,
", ");
226 g_string_append(
buffer,
"]");
230 g_string_append(
buffer,
"{");
233 g_string_append(
buffer,
", ");
236 g_string_append(
buffer,
": ");
239 g_string_append(
buffer,
"}");
243 g_string_append_printf(
buffer,
"(custom %d)",
247 g_string_append_printf(
buffer,
"<unknown type %d>",
value->type);
284 size_t value_length) {
288 value_length == 0 ? g_strdup(
"") : g_strndup(
value, value_length);
293 size_t data_length) {
296 self->values_length = data_length;
297 self->values =
static_cast<uint8_t*
>(g_malloc(
sizeof(uint8_t) * data_length));
298 memcpy(
self->values,
data,
sizeof(uint8_t) * data_length);
305 static_cast<const uint8_t*
>(g_bytes_get_data(
data, &
length));
310 size_t data_length) {
313 self->values_length = data_length;
314 self->values =
static_cast<int32_t*
>(g_malloc(
sizeof(int32_t) * data_length));
315 memcpy(
self->values,
data,
sizeof(int32_t) * data_length);
320 size_t data_length) {
323 self->values_length = data_length;
324 self->values =
static_cast<int64_t*
>(g_malloc(
sizeof(int64_t) * data_length));
325 memcpy(
self->values,
data,
sizeof(int64_t) * data_length);
330 size_t data_length) {
333 self->values_length = data_length;
334 self->values =
static_cast<float*
>(g_malloc(
sizeof(
float) * data_length));
335 memcpy(
self->values,
data,
sizeof(
float) * data_length);
340 size_t data_length) {
343 self->values_length = data_length;
344 self->values =
static_cast<double*
>(g_malloc(
sizeof(
double) * data_length));
345 memcpy(
self->values,
data,
sizeof(
double) * data_length);
357 const gchar*
const* str_array) {
358 g_return_val_if_fail(str_array !=
nullptr,
nullptr);
360 for (
int i = 0; str_array[
i] !=
nullptr;
i++) {
376 GDestroyNotify destroy_notify) {
381 self->destroy_notify = destroy_notify;
395 g_return_val_if_fail(
self !=
nullptr,
nullptr);
401 g_return_if_fail(
self !=
nullptr);
402 g_return_if_fail(
self->ref_count > 0);
404 if (
self->ref_count != 0) {
408 switch (
self->type) {
441 g_ptr_array_unref(v->
values);
446 g_ptr_array_unref(v->
keys);
447 g_ptr_array_unref(v->
values);
472 g_return_val_if_fail(
a !=
nullptr,
false);
473 g_return_val_if_fail(
b !=
nullptr,
false);
475 if (
a->type !=
b->type) {
500 if (values_a[
i] != values_b[
i]) {
513 if (values_a[
i] != values_b[
i]) {
526 if (values_a[
i] != values_b[
i]) {
539 if (values_a[
i] != values_b[
i]) {
552 if (values_a[
i] != values_b[
i]) {
577 if (value_b ==
nullptr) {
593 g_return_if_fail(
self !=
nullptr);
595 g_return_if_fail(
value !=
nullptr);
601 g_return_if_fail(
self !=
nullptr);
603 g_return_if_fail(
value !=
nullptr);
610 g_return_if_fail(
self !=
nullptr);
612 g_return_if_fail(
key !=
nullptr);
613 g_return_if_fail(
value !=
nullptr);
621 g_return_if_fail(
self !=
nullptr);
623 g_return_if_fail(
key !=
nullptr);
624 g_return_if_fail(
value !=
nullptr);
642 g_return_if_fail(
self !=
nullptr);
644 g_return_if_fail(
key !=
nullptr);
645 g_return_if_fail(
value !=
nullptr);
653 g_return_if_fail(
self !=
nullptr);
655 g_return_if_fail(
key !=
nullptr);
656 g_return_if_fail(
value !=
nullptr);
662 g_return_val_if_fail(
self !=
nullptr,
FALSE);
669 g_return_val_if_fail(
self !=
nullptr, 0);
676 g_return_val_if_fail(
self !=
nullptr, 0.0);
683 g_return_val_if_fail(
self !=
nullptr,
nullptr);
690 g_return_val_if_fail(
self !=
nullptr,
nullptr);
697 g_return_val_if_fail(
self !=
nullptr,
nullptr);
704 g_return_val_if_fail(
self !=
nullptr,
nullptr);
711 g_return_val_if_fail(
self !=
nullptr,
nullptr);
718 g_return_val_if_fail(
self !=
nullptr,
nullptr);
725 g_return_val_if_fail(
self !=
nullptr, 0);
735 switch (
self->type) {
777 g_return_val_if_fail(
self !=
nullptr,
nullptr);
781 return static_cast<FlValue*
>(g_ptr_array_index(v->
values, index));
785 g_return_val_if_fail(
self !=
nullptr,
nullptr);
789 return static_cast<FlValue*
>(g_ptr_array_index(v->
keys, index));
793 g_return_val_if_fail(
self !=
nullptr,
nullptr);
797 return static_cast<FlValue*
>(g_ptr_array_index(v->
values, index));
801 g_return_val_if_fail(
self !=
nullptr,
nullptr);
813 g_return_val_if_fail(
self !=
nullptr,
nullptr);
823 g_return_val_if_fail(
self !=
nullptr, -1);
831 g_return_val_if_fail(
self !=
nullptr,
nullptr);
839 g_return_val_if_fail(
self !=
nullptr,
nullptr);
843 return G_OBJECT(v->
value);
847 GString*
buffer = g_string_new(
"");
VULKAN_HPP_DEFAULT_DISPATCH_LOADER_DYNAMIC_STORAGE auto & d
G_MODULE_EXPORT void fl_value_set_string(FlValue *self, const gchar *key, FlValue *value)
G_MODULE_EXPORT FlValue * fl_value_new_map()
G_MODULE_EXPORT FlValue * fl_value_new_custom_object_take(int type, GObject *object)
G_MODULE_EXPORT FlValue * fl_value_ref(FlValue *self)
G_MODULE_EXPORT FlValue * fl_value_new_uint8_list_from_bytes(GBytes *data)
G_MODULE_EXPORT const double * fl_value_get_float_list(FlValue *self)
G_MODULE_EXPORT void fl_value_set_string_take(FlValue *self, const gchar *key, FlValue *value)
static void int_to_string(int64_t value, GString *buffer)
G_MODULE_EXPORT FlValue * fl_value_lookup_string(FlValue *self, const gchar *key)
static void value_to_string(FlValue *value, GString *buffer)
static void fl_value_destroy(gpointer value)
G_MODULE_EXPORT gchar * fl_value_to_string(FlValue *value)
G_MODULE_EXPORT int64_t fl_value_get_int(FlValue *self)
G_MODULE_EXPORT FlValue * fl_value_new_custom(int type, gconstpointer value, GDestroyNotify destroy_notify)
G_MODULE_EXPORT void fl_value_unref(FlValue *self)
static FlValue * fl_value_new(FlValueType type, size_t size)
G_MODULE_EXPORT FlValueType fl_value_get_type(FlValue *self)
G_MODULE_EXPORT FlValue * fl_value_new_null()
G_MODULE_EXPORT FlValue * fl_value_new_float32_list(const float *data, size_t data_length)
G_MODULE_EXPORT FlValue * fl_value_new_string(const gchar *value)
G_MODULE_EXPORT FlValue * fl_value_new_int32_list(const int32_t *data, size_t data_length)
G_MODULE_EXPORT void fl_value_append(FlValue *self, FlValue *value)
G_MODULE_EXPORT FlValue * fl_value_new_custom_object(int type, GObject *object)
G_MODULE_EXPORT FlValue * fl_value_get_map_key(FlValue *self, size_t index)
G_MODULE_EXPORT FlValue * fl_value_new_bool(bool value)
G_MODULE_EXPORT void fl_value_set_take(FlValue *self, FlValue *key, FlValue *value)
G_MODULE_EXPORT const gchar * fl_value_get_string(FlValue *self)
G_MODULE_EXPORT int fl_value_get_custom_type(FlValue *self)
G_MODULE_EXPORT FlValue * fl_value_new_int(int64_t value)
static ssize_t fl_value_lookup_index(FlValue *self, FlValue *key)
G_MODULE_EXPORT FlValue * fl_value_new_float(double value)
G_MODULE_EXPORT FlValue * fl_value_new_list_from_strv(const gchar *const *str_array)
G_MODULE_EXPORT const uint8_t * fl_value_get_uint8_list(FlValue *self)
G_MODULE_EXPORT FlValue * fl_value_lookup(FlValue *self, FlValue *key)
G_MODULE_EXPORT void fl_value_append_take(FlValue *self, FlValue *value)
G_MODULE_EXPORT gconstpointer fl_value_get_custom_value(FlValue *self)
G_MODULE_EXPORT FlValue * fl_value_get_list_value(FlValue *self, size_t index)
G_MODULE_EXPORT bool fl_value_get_bool(FlValue *self)
G_MODULE_EXPORT FlValue * fl_value_new_list()
G_MODULE_EXPORT FlValue * fl_value_new_uint8_list(const uint8_t *data, size_t data_length)
G_MODULE_EXPORT bool fl_value_equal(FlValue *a, FlValue *b)
G_MODULE_EXPORT FlValue * fl_value_new_float_list(const double *data, size_t data_length)
static void float_to_string(double value, GString *buffer)
G_MODULE_EXPORT FlValue * fl_value_new_string_sized(const gchar *value, size_t value_length)
G_MODULE_EXPORT FlValue * fl_value_new_int64_list(const int64_t *data, size_t data_length)
G_MODULE_EXPORT const float * fl_value_get_float32_list(FlValue *self)
G_MODULE_EXPORT FlValue * fl_value_get_map_value(FlValue *self, size_t index)
G_MODULE_EXPORT double fl_value_get_float(FlValue *self)
G_MODULE_EXPORT GObject * fl_value_get_custom_value_object(FlValue *self)
G_MODULE_EXPORT size_t fl_value_get_length(FlValue *self)
G_MODULE_EXPORT const int32_t * fl_value_get_int32_list(FlValue *self)
G_MODULE_EXPORT const int64_t * fl_value_get_int64_list(FlValue *self)
G_MODULE_EXPORT void fl_value_set(FlValue *self, FlValue *key, FlValue *value)
typedefG_BEGIN_DECLS struct _FlValue FlValue
@ FL_VALUE_TYPE_FLOAT32_LIST
@ FL_VALUE_TYPE_INT32_LIST
@ FL_VALUE_TYPE_UINT8_LIST
@ FL_VALUE_TYPE_INT64_LIST
@ FL_VALUE_TYPE_FLOAT_LIST
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir Path to the cache directory This is different from the persistent_cache_path in embedder which is used for Skia shader cache icu native lib Path to the library file that exports the ICU data vm service The hostname IP address on which the Dart VM Service should be served If not defaults to or::depending on whether ipv6 is specified vm service A custom Dart VM Service port The default is to pick a randomly available open port disable vm Disable the Dart VM Service The Dart VM Service is never available in release mode disable vm service Disable mDNS Dart VM Service publication Bind to the IPv6 localhost address for the Dart VM Service Ignored if vm service host is set endless trace buffer
it will be possible to load the file into Perfetto s trace viewer disable asset Prevents usage of any non test fonts unless they were explicitly Loaded via prefetched default font Indicates whether the embedding started a prefetch of the default font manager before creating the engine run In non interactive keep the shell running after the Dart script has completed enable serial On low power devices with low core running concurrent GC tasks on threads can cause them to contend with the UI thread which could potentially lead to jank This option turns off all concurrent GC activities domain network JSON encoded network policy per domain This overrides the DisallowInsecureConnections switch Embedder can specify whether to allow or disallow insecure connections at a domain level old gen heap size
GDestroyNotify destroy_notify
std::shared_ptr< const fml::Mapping > data