/* auto-generated, do not modify */
#pragma once
#include <fwupd-common.h>
typedef enum {
    FU_USWID_HEADER_FLAG_NONE = 0x0,
    FU_USWID_HEADER_FLAG_COMPRESSED = 0x1,
} FuUswidHeaderFlag;
typedef enum {
    FU_USWID_PAYLOAD_COMPRESSION_NONE = 0x00,
    FU_USWID_PAYLOAD_COMPRESSION_ZLIB = 0x01,
    FU_USWID_PAYLOAD_COMPRESSION_LZMA = 0x02,
} FuUswidPayloadCompression;
const gchar *fu_uswid_payload_compression_to_string(FuUswidPayloadCompression val);
FuUswidPayloadCompression fu_uswid_payload_compression_from_string(const gchar *val);

GByteArray *fu_struct_uswid_new(void);
GByteArray *fu_struct_uswid_parse_bytes(GBytes *blob, gsize offset, GError **error);
gboolean fu_struct_uswid_validate_bytes(GBytes *blob, gsize offset, GError **error);
guint8 fu_struct_uswid_get_hdrver(const GByteArray *st);
guint16 fu_struct_uswid_get_hdrsz(const GByteArray *st);
guint32 fu_struct_uswid_get_payloadsz(const GByteArray *st);
guint8 fu_struct_uswid_get_flags(const GByteArray *st);
guint8 fu_struct_uswid_get_compression(const GByteArray *st);
void fu_struct_uswid_set_hdrver(GByteArray *st, guint8 value);
void fu_struct_uswid_set_hdrsz(GByteArray *st, guint16 value);
void fu_struct_uswid_set_payloadsz(GByteArray *st, guint32 value);
void fu_struct_uswid_set_flags(GByteArray *st, guint8 value);
void fu_struct_uswid_set_compression(GByteArray *st, guint8 value);
#define FU_STRUCT_USWID_OFFSET_MAGIC 0x0
#define FU_STRUCT_USWID_OFFSET_HDRVER 0x10
#define FU_STRUCT_USWID_OFFSET_HDRSZ 0x11
#define FU_STRUCT_USWID_OFFSET_PAYLOADSZ 0x13
#define FU_STRUCT_USWID_OFFSET_FLAGS 0x17
#define FU_STRUCT_USWID_OFFSET_COMPRESSION 0x18
#define FU_STRUCT_USWID_SIZE_MAGIC 0x10
#define FU_STRUCT_USWID_SIZE 0x19
#define FU_STRUCT_USWID_DEFAULT_MAGIC "\x53\x42\x4F\x4D\xD6\xBA\x2E\xAC\xA3\xE6\x7A\x52\xAA\xEE\x3B\xAF"
#define FU_STRUCT_USWID_DEFAULT_HDRSZ 25
