/*
 * This file is auto-generated, do not modify!
 *
 * SPDX-License-Identifier: LGPL-2.1-or-later
 */

#pragma once
#include <fu-input-stream.h>
/**
 * FuQcReportId:
 */
typedef enum {
    /**
     * FU_QC_REPORT_ID_COMMAND:
     */
    FU_QC_REPORT_ID_COMMAND = 3,
    /**
     * FU_QC_REPORT_ID_DATA_TRANSFER:
     */
    FU_QC_REPORT_ID_DATA_TRANSFER = 5,
    /**
     * FU_QC_REPORT_ID_RESPONSE:
     */
    FU_QC_REPORT_ID_RESPONSE = 6,
}  FuQcReportId;
typedef struct {
  GByteArray *buf;
  guint refcount;
} FuStructQcHidCommand;

FuStructQcHidCommand *fu_struct_qc_hid_command_ref(FuStructQcHidCommand *st) G_GNUC_NON_NULL(1);
void fu_struct_qc_hid_command_unref(FuStructQcHidCommand *st) G_GNUC_NON_NULL(1);
G_DEFINE_AUTOPTR_CLEANUP_FUNC(FuStructQcHidCommand, fu_struct_qc_hid_command_unref)
FuStructQcHidCommand *fu_struct_qc_hid_command_new(void) G_GNUC_WARN_UNUSED_RESULT;
void fu_struct_qc_hid_command_set_payload_len(FuStructQcHidCommand *st, guint8 value) G_GNUC_NON_NULL(1);
gboolean fu_struct_qc_hid_command_set_payload(FuStructQcHidCommand *st, const guint8 *buf, gsize bufsz, GError **error) G_GNUC_NON_NULL(1, 2) G_GNUC_WARN_UNUSED_RESULT;

#ifndef __GI_SCANNER__
#define FU_STRUCT_QC_HID_COMMAND_OFFSET_REPORT_ID 0x0
#define FU_STRUCT_QC_HID_COMMAND_OFFSET_PAYLOAD_LEN 0x1
#define FU_STRUCT_QC_HID_COMMAND_OFFSET_PAYLOAD 0x2
#endif

#ifndef __GI_SCANNER__
#define FU_STRUCT_QC_HID_COMMAND_SIZE_PAYLOAD 0x3D
#define FU_STRUCT_QC_HID_COMMAND_N_ELEMENTS_PAYLOAD 61
#define FU_STRUCT_QC_HID_COMMAND_SIZE 0x3F
#endif

#ifndef __GI_SCANNER__
#define FU_STRUCT_QC_HID_COMMAND_DEFAULT_REPORT_ID FU_QC_REPORT_ID_COMMAND
#endif
typedef struct {
  GByteArray *buf;
  guint refcount;
} FuStructQcHidResponse;

FuStructQcHidResponse *fu_struct_qc_hid_response_ref(FuStructQcHidResponse *st) G_GNUC_NON_NULL(1);
void fu_struct_qc_hid_response_unref(FuStructQcHidResponse *st) G_GNUC_NON_NULL(1);
G_DEFINE_AUTOPTR_CLEANUP_FUNC(FuStructQcHidResponse, fu_struct_qc_hid_response_unref)
FuStructQcHidResponse *fu_struct_qc_hid_response_parse(const guint8 *buf, gsize bufsz, gsize offset, GError **error) G_GNUC_NON_NULL(1) G_GNUC_WARN_UNUSED_RESULT;
guint8 fu_struct_qc_hid_response_get_payload_len(const FuStructQcHidResponse *st) G_GNUC_NON_NULL(1) G_GNUC_WARN_UNUSED_RESULT;
const guint8 *fu_struct_qc_hid_response_get_payload(const FuStructQcHidResponse *st, gsize *bufsz) G_GNUC_NON_NULL(1) G_GNUC_WARN_UNUSED_RESULT;

#ifndef __GI_SCANNER__
#define FU_STRUCT_QC_HID_RESPONSE_OFFSET_REPORT_ID 0x0
#define FU_STRUCT_QC_HID_RESPONSE_OFFSET_PAYLOAD_LEN 0x1
#define FU_STRUCT_QC_HID_RESPONSE_OFFSET_PAYLOAD 0x2
#endif

#ifndef __GI_SCANNER__
#define FU_STRUCT_QC_HID_RESPONSE_SIZE_PAYLOAD 0xB
#define FU_STRUCT_QC_HID_RESPONSE_N_ELEMENTS_PAYLOAD 11
#define FU_STRUCT_QC_HID_RESPONSE_SIZE 0xD
#endif

#ifndef __GI_SCANNER__
#define FU_STRUCT_QC_HID_RESPONSE_DEFAULT_REPORT_ID FU_QC_REPORT_ID_RESPONSE
#endif
typedef struct {
  GByteArray *buf;
  guint refcount;
} FuStructQcHidDataTransfer;

FuStructQcHidDataTransfer *fu_struct_qc_hid_data_transfer_ref(FuStructQcHidDataTransfer *st) G_GNUC_NON_NULL(1);
void fu_struct_qc_hid_data_transfer_unref(FuStructQcHidDataTransfer *st) G_GNUC_NON_NULL(1);
G_DEFINE_AUTOPTR_CLEANUP_FUNC(FuStructQcHidDataTransfer, fu_struct_qc_hid_data_transfer_unref)
FuStructQcHidDataTransfer *fu_struct_qc_hid_data_transfer_new(void) G_GNUC_WARN_UNUSED_RESULT;
void fu_struct_qc_hid_data_transfer_set_payload_len(FuStructQcHidDataTransfer *st, guint8 value) G_GNUC_NON_NULL(1);
gboolean fu_struct_qc_hid_data_transfer_set_payload(FuStructQcHidDataTransfer *st, const guint8 *buf, gsize bufsz, GError **error) G_GNUC_NON_NULL(1, 2) G_GNUC_WARN_UNUSED_RESULT;

#ifndef __GI_SCANNER__
#define FU_STRUCT_QC_HID_DATA_TRANSFER_OFFSET_REPORT_ID 0x0
#define FU_STRUCT_QC_HID_DATA_TRANSFER_OFFSET_PAYLOAD_LEN 0x1
#define FU_STRUCT_QC_HID_DATA_TRANSFER_OFFSET_PAYLOAD 0x2
#endif

#ifndef __GI_SCANNER__
#define FU_STRUCT_QC_HID_DATA_TRANSFER_SIZE_PAYLOAD 0xFD
#define FU_STRUCT_QC_HID_DATA_TRANSFER_N_ELEMENTS_PAYLOAD 253
#define FU_STRUCT_QC_HID_DATA_TRANSFER_SIZE 0xFF
#endif

#ifndef __GI_SCANNER__
#define FU_STRUCT_QC_HID_DATA_TRANSFER_DEFAULT_REPORT_ID FU_QC_REPORT_ID_DATA_TRANSFER
#endif
