#pragma once

#include "main.h"

#include <vector>
#include <string>
#include <map>

typedef struct 
{
    std::string saddr;
    std::string desc;
    std::string type_str;
    std::string default_value;
    uint8_t type;
    uint16_t inf;
}stru_param_cfg_data;


typedef struct 
{
    uint8_t md5[16];
    std::map<uint8_t, std::vector<stru_param_cfg_data>> map_type_param;
    std::vector<stru_param_cfg_data> vec_param;
}stru_param_cfg;





typedef struct
{
    std::string saddr;
    std::string desc;
    uint16_t inf;
}stru_st_mx_co_dd_info;


typedef struct
{
    std::vector<stru_st_mx_co_dd_info> st_info_vec;
    std::vector<stru_st_mx_co_dd_info> mx_info_vec;
    std::vector<stru_st_mx_co_dd_info> co_info_vec;
    std::vector<stru_st_mx_co_dd_info> dd_info_vec;

    stru_param_cfg param_cfg;
}stru_ftu_cfg;


int parse_ftu_cfg(const std::string &cfg_path);

stru_ftu_cfg *get_ftu_cfg_ptr(void);
