| // SPDX-License-Identifier: (GPL-2.0-only OR MIT) |
| /* |
| * Copyright (C) 2024 Amlogic, Inc. All rights reserved |
| */ |
| |
| #ifndef BINC_UTILITY_H |
| #define BINC_UTILITY_H |
| |
| #include <glib.h> |
| |
| #ifdef __cplusplus |
| extern "C" { |
| #endif |
| |
| GString *g_byte_array_as_hex(const GByteArray *byteArray); |
| |
| GList *g_variant_string_array_to_list(GVariant *value); |
| |
| float binc_round_with_precision(float value, guint8 precision); |
| |
| gchar *binc_date_time_format_iso8601(GDateTime *datetime); |
| |
| gboolean is_lowercase(const char *str); |
| |
| gboolean is_valid_uuid(const char *uuid); |
| |
| char *path_to_address(const char *path); |
| |
| GByteArray *g_variant_get_byte_array(GVariant *variant); |
| |
| char* replace_char(char* str, char find, char replace); |
| |
| #ifdef __cplusplus |
| } |
| #endif |
| |
| #endif //BINC_UTILITY_H |