////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.
// All Rights Reserved.
// Confidential and Proprietary - Qualcomm Technologies, Inc.
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// THIS IS AUTO-GENERATED CODE.  PLEASE DO NOT EDIT (File bug reports against tools).
///
/// Auto-generated by: Parameter Parser V5.5.1 (2411131018)
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// @file  aecxmtrtablegen.cpp
/// @brief Auto-generated Chromatix parameter file
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

#include "aecxmtrtablegen.h"
#include "parametersetmanager.h"

AECXMTRTABLEGEN_NAMESPACE_BEGIN

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// SetValue/GetValue Functions
/// Gets or sets the requested value
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool GeneratorOutputType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "output2DWeightID") == 0)
    {
        ParameterUtils::DoubleToString((double)output2DWeightID, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "enableGetWeightAverage") == 0)
    {
        ParameterUtils::DoubleToString((double)enableGetWeightAverage, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "outputWeightAverageTriggerID") == 0)
    {
        ParameterUtils::DoubleToString((double)outputWeightAverageTriggerID, __value, __size, 0);
        __result = true;
    }

    return __result;
}

bool GeneratorOutputType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "output2DWeightID") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            output2DWeightID = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "enableGetWeightAverage") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            enableGetWeightAverage = (BOOL)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "outputWeightAverageTriggerID") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            outputWeightAverageTriggerID = (INT32)dblValue; 
        }
    }

    return __result;
}

bool GeneratorOutputType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // output2DWeightID
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("output2DWeightID", ParameterParserDataType::Int32, (double)output2DWeightID, 0));
    }
    else if (PARAMETER_STRCMP(__name, "output2DWeightID") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)output2DWeightID, 0));
    }

    // enableGetWeightAverage
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("enableGetWeightAverage", ParameterParserDataType::Boolean, (double)enableGetWeightAverage, 0));
    }
    else if (PARAMETER_STRCMP(__name, "enableGetWeightAverage") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Boolean, (double)enableGetWeightAverage, 0));
    }

    // outputWeightAverageTriggerID
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("outputWeightAverageTriggerID", ParameterParserDataType::Int32, (double)outputWeightAverageTriggerID, 0));
    }
    else if (PARAMETER_STRCMP(__name, "outputWeightAverageTriggerID") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)outputWeightAverageTriggerID, 0));
    }

    return __result;
}

bool GeneratorSourceType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "base2DWeightID") == 0)
    {
        ParameterUtils::DoubleToString((double)base2DWeightID, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "statsChannel") == 0)
    {
        PARAMETER_STRCPY(__value, __size, statsChannel);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "externData2DWeightID") == 0)
    {
        ParameterUtils::DoubleToString((double)externData2DWeightID, __value, __size, 0);
        __result = true;
    }

    return __result;
}

bool GeneratorSourceType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "base2DWeightID") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            base2DWeightID = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "statsChannel") == 0)
    {
        // Cannot modify strings, risk of memory leaks or corruption
    }
    else if (PARAMETER_STRCMP(__name, "externData2DWeightID") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            externData2DWeightID = (INT32)dblValue; 
        }
    }

    return __result;
}

bool GeneratorSourceType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // base2DWeightID
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("base2DWeightID", ParameterParserDataType::Int32, (double)base2DWeightID, 0));
    }
    else if (PARAMETER_STRCMP(__name, "base2DWeightID") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)base2DWeightID, 0));
    }

    // statsChannel
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("statsChannel", ParameterParserDataType::String, statsChannel));
    }
    else if (PARAMETER_STRCMP(__name, "statsChannel") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::String, statsChannel));
    }

    // externData2DWeightID
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("externData2DWeightID", ParameterParserDataType::Int32, (double)externData2DWeightID, 0));
    }
    else if (PARAMETER_STRCMP(__name, "externData2DWeightID") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)externData2DWeightID, 0));
    }

    return __result;
}

bool GeneratorEndLevelDataType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "trigger2") == 0)
    {
        __result = trigger2.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "triggerData") == 0)
    {
        __result = triggerData.GetValue(&__path[__pos], __value, __size);
    }

    return __result;
}

bool GeneratorEndLevelDataType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "trigger2") == 0)
    {
        __result = trigger2.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "triggerData") == 0)
    {
        __result = triggerData.SetValue(&__path[__pos], __value);
    }

    return __result;
}

bool GeneratorEndLevelDataType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // trigger2
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("trigger2", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "trigger2") == 0)
    {
        __result = trigger2.GetInfo(&__path[__pos], __info);
    }

    // triggerData
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("triggerData", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "triggerData") == 0)
    {
        __result = triggerData.GetInfo(&__path[__pos], __info);
    }

    return __result;
}

bool GeneratorTwoLevelTriggerSystemType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "trigger1Lux") == 0)
    {
        __result = trigger1Lux.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "trigger2Data") == 0)
    {
        if (__index < trigger2DataCount)
        {
            __result = trigger2Data[__index].GetValue(&__path[__pos], __value, __size);
        }
    }

    return __result;
}

bool GeneratorTwoLevelTriggerSystemType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "trigger1Lux") == 0)
    {
        __result = trigger1Lux.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "trigger2Data") == 0)
    {
        if (__index < trigger2DataCount)
        {
            __result = trigger2Data[__index].SetValue(&__path[__pos], __value);
        }
    }

    return __result;
}

bool GeneratorTwoLevelTriggerSystemType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // trigger1Lux
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("trigger1Lux", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "trigger1Lux") == 0)
    {
        __result = trigger1Lux.GetInfo(&__path[__pos], __info);
    }

    // trigger2Data
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("trigger2Data", ParameterParserDataType::Structure, true, false, trigger2DataCount));
    }
    else if (PARAMETER_STRCMP(__name, "trigger2Data") == 0)
    {
        if (__index < trigger2DataCount)
        {
            __result = trigger2Data[__index].GetInfo(&__path[__pos], __info);
        }
        else
        {
            __result = true;
            __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Structure, true, false, trigger2DataCount));
        }
    }

    return __result;
}

bool DataDrivenTriggerSystemType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "trigger1Data") == 0)
    {
        if (__index < trigger1DataCount)
        {
            __result = trigger1Data[__index].GetValue(&__path[__pos], __value, __size);
        }
    }

    return __result;
}

bool DataDrivenTriggerSystemType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "trigger1Data") == 0)
    {
        if (__index < trigger1DataCount)
        {
            __result = trigger1Data[__index].SetValue(&__path[__pos], __value);
        }
    }

    return __result;
}

bool DataDrivenTriggerSystemType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // trigger1Data
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("trigger1Data", ParameterParserDataType::Structure, true, false, trigger1DataCount));
    }
    else if (PARAMETER_STRCMP(__name, "trigger1Data") == 0)
    {
        if (__index < trigger1DataCount)
        {
            __result = trigger1Data[__index].GetInfo(&__path[__pos], __info);
        }
        else
        {
            __result = true;
            __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Structure, true, false, trigger1DataCount));
        }
    }

    return __result;
}

bool TableGeneratorType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "enable") == 0)
    {
        ParameterUtils::DoubleToString((double)enable, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "method") == 0)
    {
        ParameterUtils::DoubleToString((double)(UINT32)method, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "input") == 0)
    {
        __result = input.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "output") == 0)
    {
        __result = output.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "triggerSystem") == 0)
    {
        __result = triggerSystem.GetValue(&__path[__pos], __value, __size);
    }

    return __result;
}

bool TableGeneratorType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "enable") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            enable = (BOOL)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "method") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            method = (GenerationMethodType)(UINT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "input") == 0)
    {
        __result = input.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "output") == 0)
    {
        __result = output.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "triggerSystem") == 0)
    {
        __result = triggerSystem.SetValue(&__path[__pos], __value);
    }

    return __result;
}

bool TableGeneratorType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // enable
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("enable", ParameterParserDataType::Boolean, (double)enable, 0));
    }
    else if (PARAMETER_STRCMP(__name, "enable") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Boolean, (double)enable, 0));
    }

    // method
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("method", ParameterParserDataType::Enum, (double)(UINT32)method, 0));
    }
    else if (PARAMETER_STRCMP(__name, "method") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Enum, (double)(UINT32)method, 0));
    }

    // input
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("input", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "input") == 0)
    {
        __result = input.GetInfo(&__path[__pos], __info);
    }

    // output
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("output", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "output") == 0)
    {
        __result = output.GetInfo(&__path[__pos], __info);
    }

    // triggerSystem
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("triggerSystem", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "triggerSystem") == 0)
    {
        __result = triggerSystem.GetInfo(&__path[__pos], __info);
    }

    return __result;
}

bool PrecisionFlashType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "enable") == 0)
    {
        ParameterUtils::DoubleToString((double)enable, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "BackGrdMask") == 0)
    {
        __result = BackGrdMask.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "ForeGrdMask") == 0)
    {
        __result = ForeGrdMask.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "BackGrdPctDataID") == 0)
    {
        ParameterUtils::DoubleToString((double)BackGrdPctDataID, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "BackGrdBiasTblID") == 0)
    {
        ParameterUtils::DoubleToString((double)BackGrdBiasTblID, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "ForeGrdBiasTblID") == 0)
    {
        ParameterUtils::DoubleToString((double)ForeGrdBiasTblID, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "HighPct") == 0)
    {
        ParameterUtils::DoubleToString((double)HighPct, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "BackGrdThld") == 0)
    {
        ParameterUtils::DoubleToString((double)BackGrdThld, __value, __size);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "ForeGrdThld") == 0)
    {
        ParameterUtils::DoubleToString((double)ForeGrdThld, __value, __size);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "DetectionType") == 0)
    {
        ParameterUtils::DoubleToString((double)DetectionType, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "MinPxlVal") == 0)
    {
        ParameterUtils::DoubleToString((double)MinPxlVal, __value, __size);
        __result = true;
    }

    return __result;
}

bool PrecisionFlashType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "enable") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            enable = (BOOL)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "BackGrdMask") == 0)
    {
        __result = BackGrdMask.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "ForeGrdMask") == 0)
    {
        __result = ForeGrdMask.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "BackGrdPctDataID") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            BackGrdPctDataID = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "BackGrdBiasTblID") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            BackGrdBiasTblID = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "ForeGrdBiasTblID") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            ForeGrdBiasTblID = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "HighPct") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            HighPct = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "BackGrdThld") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            BackGrdThld = (float)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "ForeGrdThld") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            ForeGrdThld = (float)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "DetectionType") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            DetectionType = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "MinPxlVal") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            MinPxlVal = (float)dblValue; 
        }
    }

    return __result;
}

bool PrecisionFlashType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // enable
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("enable", ParameterParserDataType::Boolean, (double)enable, 0));
    }
    else if (PARAMETER_STRCMP(__name, "enable") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Boolean, (double)enable, 0));
    }

    // BackGrdMask
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("BackGrdMask", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "BackGrdMask") == 0)
    {
        __result = BackGrdMask.GetInfo(&__path[__pos], __info);
    }

    // ForeGrdMask
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("ForeGrdMask", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "ForeGrdMask") == 0)
    {
        __result = ForeGrdMask.GetInfo(&__path[__pos], __info);
    }

    // BackGrdPctDataID
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("BackGrdPctDataID", ParameterParserDataType::Int32, (double)BackGrdPctDataID, 0));
    }
    else if (PARAMETER_STRCMP(__name, "BackGrdPctDataID") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)BackGrdPctDataID, 0));
    }

    // BackGrdBiasTblID
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("BackGrdBiasTblID", ParameterParserDataType::Int32, (double)BackGrdBiasTblID, 0));
    }
    else if (PARAMETER_STRCMP(__name, "BackGrdBiasTblID") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)BackGrdBiasTblID, 0));
    }

    // ForeGrdBiasTblID
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("ForeGrdBiasTblID", ParameterParserDataType::Int32, (double)ForeGrdBiasTblID, 0));
    }
    else if (PARAMETER_STRCMP(__name, "ForeGrdBiasTblID") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)ForeGrdBiasTblID, 0));
    }

    // HighPct
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("HighPct", ParameterParserDataType::Int32, (double)HighPct, 0));
    }
    else if (PARAMETER_STRCMP(__name, "HighPct") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)HighPct, 0));
    }

    // BackGrdThld
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("BackGrdThld", ParameterParserDataType::Float, (double)BackGrdThld));
    }
    else if (PARAMETER_STRCMP(__name, "BackGrdThld") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)BackGrdThld));
    }

    // ForeGrdThld
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("ForeGrdThld", ParameterParserDataType::Float, (double)ForeGrdThld));
    }
    else if (PARAMETER_STRCMP(__name, "ForeGrdThld") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)ForeGrdThld));
    }

    // DetectionType
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("DetectionType", ParameterParserDataType::Int32, (double)DetectionType, 0));
    }
    else if (PARAMETER_STRCMP(__name, "DetectionType") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)DetectionType, 0));
    }

    // MinPxlVal
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("MinPxlVal", ParameterParserDataType::Float, (double)MinPxlVal));
    }
    else if (PARAMETER_STRCMP(__name, "MinPxlVal") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)MinPxlVal));
    }

    return __result;
}

bool SmartFlashMotionAssistType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "enable") == 0)
    {
        ParameterUtils::DoubleToString((double)enable, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "motionTh") == 0)
    {
        ParameterUtils::DoubleToString((double)motionTh, __value, __size);
        __result = true;
    }

    return __result;
}

bool SmartFlashMotionAssistType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "enable") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            enable = (BOOL)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "motionTh") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            motionTh = (float)dblValue; 
        }
    }

    return __result;
}

bool SmartFlashMotionAssistType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // enable
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("enable", ParameterParserDataType::Boolean, (double)enable, 0));
    }
    else if (PARAMETER_STRCMP(__name, "enable") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Boolean, (double)enable, 0));
    }

    // motionTh
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("motionTh", ParameterParserDataType::Float, (double)motionTh));
    }
    else if (PARAMETER_STRCMP(__name, "motionTh") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)motionTh));
    }

    return __result;
}

bool SmartFlashDepthAssistType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "enable") == 0)
    {
        ParameterUtils::DoubleToString((double)enable, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "distanceTh") == 0)
    {
        ParameterUtils::DoubleToString((double)distanceTh, __value, __size);
        __result = true;
    }

    return __result;
}

bool SmartFlashDepthAssistType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "enable") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            enable = (BOOL)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "distanceTh") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            distanceTh = (float)dblValue; 
        }
    }

    return __result;
}

bool SmartFlashDepthAssistType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // enable
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("enable", ParameterParserDataType::Boolean, (double)enable, 0));
    }
    else if (PARAMETER_STRCMP(__name, "enable") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Boolean, (double)enable, 0));
    }

    // distanceTh
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("distanceTh", ParameterParserDataType::Float, (double)distanceTh));
    }
    else if (PARAMETER_STRCMP(__name, "distanceTh") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)distanceTh));
    }

    return __result;
}

bool SmartFlashConfType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "enable") == 0)
    {
        ParameterUtils::DoubleToString((double)enable, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "lumaHighSatTh") == 0)
    {
        ParameterUtils::DoubleToString((double)lumaHighSatTh, __value, __size);
        __result = true;
    }

    return __result;
}

bool SmartFlashConfType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "enable") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            enable = (BOOL)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "lumaHighSatTh") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            lumaHighSatTh = (float)dblValue; 
        }
    }

    return __result;
}

bool SmartFlashConfType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // enable
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("enable", ParameterParserDataType::Boolean, (double)enable, 0));
    }
    else if (PARAMETER_STRCMP(__name, "enable") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Boolean, (double)enable, 0));
    }

    // lumaHighSatTh
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("lumaHighSatTh", ParameterParserDataType::Float, (double)lumaHighSatTh));
    }
    else if (PARAMETER_STRCMP(__name, "lumaHighSatTh") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)lumaHighSatTh));
    }

    return __result;
}

bool FlashBiasMtrTblGenCoreConfigType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "dataBankID") == 0)
    {
        ParameterUtils::DoubleToString((double)dataBankID, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "baseTableID") == 0)
    {
        ParameterUtils::DoubleToString((double)baseTableID, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "thresBrightSat") == 0)
    {
        ParameterUtils::DoubleToString((double)thresBrightSat, __value, __size);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "flashEstStrength") == 0)
    {
        ParameterUtils::DoubleToString((double)flashEstStrength, __value, __size);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "minOffStats") == 0)
    {
        ParameterUtils::DoubleToString((double)minOffStats, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "kFloorPct") == 0)
    {
        ParameterUtils::DoubleToString((double)kFloorPct, __value, __size);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "satPreventStrength") == 0)
    {
        ParameterUtils::DoubleToString((double)satPreventStrength, __value, __size);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "SpeckleScreen") == 0)
    {
        __result = SpeckleScreen.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "flashBiasConf") == 0)
    {
        __result = flashBiasConf.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "depthAssist") == 0)
    {
        __result = depthAssist.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "motionAssist") == 0)
    {
        __result = motionAssist.GetValue(&__path[__pos], __value, __size);
    }

    return __result;
}

bool FlashBiasMtrTblGenCoreConfigType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "dataBankID") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            dataBankID = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "baseTableID") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            baseTableID = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "thresBrightSat") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            thresBrightSat = (float)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "flashEstStrength") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            flashEstStrength = (float)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "minOffStats") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            minOffStats = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "kFloorPct") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            kFloorPct = (float)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "satPreventStrength") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            satPreventStrength = (float)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "SpeckleScreen") == 0)
    {
        __result = SpeckleScreen.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "flashBiasConf") == 0)
    {
        __result = flashBiasConf.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "depthAssist") == 0)
    {
        __result = depthAssist.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "motionAssist") == 0)
    {
        __result = motionAssist.SetValue(&__path[__pos], __value);
    }

    return __result;
}

bool FlashBiasMtrTblGenCoreConfigType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // dataBankID
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("dataBankID", ParameterParserDataType::Int32, (double)dataBankID, 0));
    }
    else if (PARAMETER_STRCMP(__name, "dataBankID") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)dataBankID, 0));
    }

    // baseTableID
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("baseTableID", ParameterParserDataType::Int32, (double)baseTableID, 0));
    }
    else if (PARAMETER_STRCMP(__name, "baseTableID") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)baseTableID, 0));
    }

    // thresBrightSat
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("thresBrightSat", ParameterParserDataType::Float, (double)thresBrightSat));
    }
    else if (PARAMETER_STRCMP(__name, "thresBrightSat") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)thresBrightSat));
    }

    // flashEstStrength
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("flashEstStrength", ParameterParserDataType::Float, (double)flashEstStrength));
    }
    else if (PARAMETER_STRCMP(__name, "flashEstStrength") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)flashEstStrength));
    }

    // minOffStats
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("minOffStats", ParameterParserDataType::Int32, (double)minOffStats, 0));
    }
    else if (PARAMETER_STRCMP(__name, "minOffStats") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)minOffStats, 0));
    }

    // kFloorPct
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("kFloorPct", ParameterParserDataType::Float, (double)kFloorPct));
    }
    else if (PARAMETER_STRCMP(__name, "kFloorPct") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)kFloorPct));
    }

    // satPreventStrength
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("satPreventStrength", ParameterParserDataType::Float, (double)satPreventStrength));
    }
    else if (PARAMETER_STRCMP(__name, "satPreventStrength") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)satPreventStrength));
    }

    // SpeckleScreen
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("SpeckleScreen", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "SpeckleScreen") == 0)
    {
        __result = SpeckleScreen.GetInfo(&__path[__pos], __info);
    }

    // flashBiasConf
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("flashBiasConf", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "flashBiasConf") == 0)
    {
        __result = flashBiasConf.GetInfo(&__path[__pos], __info);
    }

    // depthAssist
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("depthAssist", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "depthAssist") == 0)
    {
        __result = depthAssist.GetInfo(&__path[__pos], __info);
    }

    // motionAssist
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("motionAssist", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "motionAssist") == 0)
    {
        __result = motionAssist.GetInfo(&__path[__pos], __info);
    }

    return __result;
}

bool FlashBiasMtrTblGenCoreConfigType::SpeckleScreenStruct::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "enable") == 0)
    {
        ParameterUtils::DoubleToString((double)enable, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "range") == 0)
    {
        __result = range.GetValue(&__path[__pos], __value, __size);
    }

    return __result;
}

bool FlashBiasMtrTblGenCoreConfigType::SpeckleScreenStruct::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "enable") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            enable = (BOOL)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "range") == 0)
    {
        __result = range.SetValue(&__path[__pos], __value);
    }

    return __result;
}

bool FlashBiasMtrTblGenCoreConfigType::SpeckleScreenStruct::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // enable
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("enable", ParameterParserDataType::Boolean, (double)enable, 0));
    }
    else if (PARAMETER_STRCMP(__name, "enable") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Boolean, (double)enable, 0));
    }

    // range
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("range", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "range") == 0)
    {
        __result = range.GetInfo(&__path[__pos], __info);
    }

    return __result;
}

bool MtrStatsSelectionType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "channel1") == 0)
    {
        PARAMETER_STRCPY(__value, __size, channel1);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "channel2") == 0)
    {
        PARAMETER_STRCPY(__value, __size, channel2);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "channel3") == 0)
    {
        PARAMETER_STRCPY(__value, __size, channel3);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "channel4") == 0)
    {
        PARAMETER_STRCPY(__value, __size, channel4);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "channel5") == 0)
    {
        PARAMETER_STRCPY(__value, __size, channel5);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "type") == 0)
    {
        ParameterUtils::DoubleToString((double)(UINT32)type, __value, __size, 0);
        __result = true;
    }

    return __result;
}

bool MtrStatsSelectionType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "channel1") == 0)
    {
        // Cannot modify strings, risk of memory leaks or corruption
    }
    else if (PARAMETER_STRCMP(__name, "channel2") == 0)
    {
        // Cannot modify strings, risk of memory leaks or corruption
    }
    else if (PARAMETER_STRCMP(__name, "channel3") == 0)
    {
        // Cannot modify strings, risk of memory leaks or corruption
    }
    else if (PARAMETER_STRCMP(__name, "channel4") == 0)
    {
        // Cannot modify strings, risk of memory leaks or corruption
    }
    else if (PARAMETER_STRCMP(__name, "channel5") == 0)
    {
        // Cannot modify strings, risk of memory leaks or corruption
    }
    else if (PARAMETER_STRCMP(__name, "type") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            type = (aecxglobalelements::AECXStatsType)(UINT32)dblValue; 
        }
    }

    return __result;
}

bool MtrStatsSelectionType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // channel1
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("channel1", ParameterParserDataType::String, channel1));
    }
    else if (PARAMETER_STRCMP(__name, "channel1") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::String, channel1));
    }

    // channel2
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("channel2", ParameterParserDataType::String, channel2));
    }
    else if (PARAMETER_STRCMP(__name, "channel2") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::String, channel2));
    }

    // channel3
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("channel3", ParameterParserDataType::String, channel3));
    }
    else if (PARAMETER_STRCMP(__name, "channel3") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::String, channel3));
    }

    // channel4
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("channel4", ParameterParserDataType::String, channel4));
    }
    else if (PARAMETER_STRCMP(__name, "channel4") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::String, channel4));
    }

    // channel5
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("channel5", ParameterParserDataType::String, channel5));
    }
    else if (PARAMETER_STRCMP(__name, "channel5") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::String, channel5));
    }

    // type
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("type", ParameterParserDataType::Enum, (double)(UINT32)type, 0));
    }
    else if (PARAMETER_STRCMP(__name, "type") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Enum, (double)(UINT32)type, 0));
    }

    return __result;
}

bool FlashBiasMtrTblGenConfigType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "statsSelection") == 0)
    {
        __result = statsSelection.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "mtrTblConfig") == 0)
    {
        __result = mtrTblConfig.GetValue(&__path[__pos], __value, __size);
    }

    return __result;
}

bool FlashBiasMtrTblGenConfigType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "statsSelection") == 0)
    {
        __result = statsSelection.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "mtrTblConfig") == 0)
    {
        __result = mtrTblConfig.SetValue(&__path[__pos], __value);
    }

    return __result;
}

bool FlashBiasMtrTblGenConfigType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // statsSelection
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("statsSelection", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "statsSelection") == 0)
    {
        __result = statsSelection.GetInfo(&__path[__pos], __info);
    }

    // mtrTblConfig
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("mtrTblConfig", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "mtrTblConfig") == 0)
    {
        __result = mtrTblConfig.GetInfo(&__path[__pos], __info);
    }

    return __result;
}

bool AECXMtrTableGenType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "module_version") == 0)
    {
        __result = module_version.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "parameter_version") == 0)
    {
        __result = parameter_version.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "moduleID") == 0)
    {
        ParameterUtils::DoubleToString((double)(UINT32)moduleID, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "flashBiasMetTblGen") == 0)
    {
        __result = flashBiasMetTblGen.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "PrecisionFlashTblGen") == 0)
    {
        __result = PrecisionFlashTblGen.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "tableGenerator") == 0)
    {
        if (__index < tableGeneratorCount)
        {
            __result = tableGenerator[__index].GetValue(&__path[__pos], __value, __size);
        }
    }

    return __result;
}

bool AECXMtrTableGenType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "module_version") == 0)
    {
        __result = module_version.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "parameter_version") == 0)
    {
        __result = parameter_version.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "moduleID") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            moduleID = (aecxglobalelements::AECXModuleIDType)(UINT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "flashBiasMetTblGen") == 0)
    {
        __result = flashBiasMetTblGen.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "PrecisionFlashTblGen") == 0)
    {
        __result = PrecisionFlashTblGen.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "tableGenerator") == 0)
    {
        if (__index < tableGeneratorCount)
        {
            __result = tableGenerator[__index].SetValue(&__path[__pos], __value);
        }
    }

    return __result;
}

bool AECXMtrTableGenType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // module_version
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("module_version", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "module_version") == 0)
    {
        __result = module_version.GetInfo(&__path[__pos], __info);
    }

    // parameter_version
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("parameter_version", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "parameter_version") == 0)
    {
        __result = parameter_version.GetInfo(&__path[__pos], __info);
    }

    // moduleID
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("moduleID", ParameterParserDataType::Enum, (double)(UINT32)moduleID, 0));
    }
    else if (PARAMETER_STRCMP(__name, "moduleID") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Enum, (double)(UINT32)moduleID, 0));
    }

    // flashBiasMetTblGen
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("flashBiasMetTblGen", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "flashBiasMetTblGen") == 0)
    {
        __result = flashBiasMetTblGen.GetInfo(&__path[__pos], __info);
    }

    // PrecisionFlashTblGen
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("PrecisionFlashTblGen", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "PrecisionFlashTblGen") == 0)
    {
        __result = PrecisionFlashTblGen.GetInfo(&__path[__pos], __info);
    }

    // tableGenerator
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("tableGenerator", ParameterParserDataType::Structure, true, false, tableGeneratorCount));
    }
    else if (PARAMETER_STRCMP(__name, "tableGenerator") == 0)
    {
        if (__index < tableGeneratorCount)
        {
            __result = tableGenerator[__index].GetInfo(&__path[__pos], __info);
        }
        else
        {
            __result = true;
            __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Structure, true, false, tableGeneratorCount));
        }
    }

    return __result;
}

bool AECXMtrTableGenType::module_versionStruct::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "major_revision") == 0)
    {
        ParameterUtils::DoubleToString((double)major_revision, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "minor_revision") == 0)
    {
        ParameterUtils::DoubleToString((double)minor_revision, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "incr_revision") == 0)
    {
        ParameterUtils::DoubleToString((double)incr_revision, __value, __size, 0);
        __result = true;
    }

    return __result;
}

bool AECXMtrTableGenType::module_versionStruct::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "major_revision") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            major_revision = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "minor_revision") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            minor_revision = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "incr_revision") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            incr_revision = (INT32)dblValue; 
        }
    }

    return __result;
}

bool AECXMtrTableGenType::module_versionStruct::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // major_revision
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("major_revision", ParameterParserDataType::Int32, (double)major_revision, 0));
    }
    else if (PARAMETER_STRCMP(__name, "major_revision") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)major_revision, 0));
    }

    // minor_revision
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("minor_revision", ParameterParserDataType::Int32, (double)minor_revision, 0));
    }
    else if (PARAMETER_STRCMP(__name, "minor_revision") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)minor_revision, 0));
    }

    // incr_revision
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("incr_revision", ParameterParserDataType::Int32, (double)incr_revision, 0));
    }
    else if (PARAMETER_STRCMP(__name, "incr_revision") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)incr_revision, 0));
    }

    return __result;
}

bool AECXMtrTableGenType::parameter_versionStruct::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "revision") == 0)
    {
        PARAMETER_STRCPY(__value, __size, revision);
        __result = true;
    }

    return __result;
}

bool AECXMtrTableGenType::parameter_versionStruct::SetValue(
    const CHAR* const __path,
    const CHAR* const /*__value*/)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "revision") == 0)
    {
        // Cannot modify strings, risk of memory leaks or corruption
    }

    return __result;
}

bool AECXMtrTableGenType::parameter_versionStruct::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // revision
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("revision", ParameterParserDataType::String, revision));
    }
    else if (PARAMETER_STRCMP(__name, "revision") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::String, revision));
    }

    return __result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// @brief Read enum value
/// @param entry [in] Symbol table entry
/// @param enumValue [out] Enum value to read
/// @param alignment [in] Symbol table byte alignment
/// @return true if successful
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool ReadEnum_GenerationMethodType(
    ParameterFileSymbolTableEntry* const entry,
    GenerationMethodType& enumValue,
    BYTE const alignment)
{
    bool result {false};

    UINT32 uintValue {entry->ReadEnum(&result, alignment)};

    if (result)
    {
        switch (uintValue)
        {
        case static_cast<UINT32>(GenerationMethodType::StatsDrivenMethod):
            enumValue = GenerationMethodType::StatsDrivenMethod;
            result    = true;
            break;
        case static_cast<UINT32>(GenerationMethodType::ExternalDataDrivenMethod):
            enumValue = GenerationMethodType::ExternalDataDrivenMethod;
            result    = true;
            break;
        default:
            PARAMETER_LOG_ERROR(entry->SetManager, "Invalid value(% u) converting UINT32 to GenerationMethodType", uintValue);
            break;
        }
    }
    return result;
}


////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Default Constructor
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
AECXMtrTableGenTypeClass::AECXMtrTableGenTypeClass(
    const CHAR* const name)
    : ParameterModule(name, MAJOR, MINOR, PATCH, nullptr)
{
    PARAMETER_INITIALIZE(SymbolTableID);
    PARAMETER_INITIALIZE(module_version);
    PARAMETER_INITIALIZE(parameter_version);
    PARAMETER_INITIALIZE(moduleID);
    PARAMETER_INITIALIZE(flashBiasMetTblGen);
    PARAMETER_INITIALIZE(PrecisionFlashTblGen);
    PARAMETER_INITIALIZE(tableGeneratorCount);
    PARAMETER_INITIALIZE(tableGenerator);
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Constructor
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
AECXMtrTableGenTypeClass::AECXMtrTableGenTypeClass(
    const CHAR* const name,
    ModuleData* const moduleData)
    : ParameterModule(name, MAJOR, MINOR, PATCH, moduleData)
{
    PARAMETER_INITIALIZE(SymbolTableID);
    PARAMETER_INITIALIZE(module_version);
    PARAMETER_INITIALIZE(parameter_version);
    PARAMETER_INITIALIZE(moduleID);
    PARAMETER_INITIALIZE(flashBiasMetTblGen);
    PARAMETER_INITIALIZE(PrecisionFlashTblGen);
    PARAMETER_INITIALIZE(tableGenerator);
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Destructor
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
AECXMtrTableGenTypeClass::~AECXMtrTableGenTypeClass()
{
    if (Loaded)
    {
        UnloadModule();
    }
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// GetName
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
const CHAR* AECXMtrTableGenTypeClass::GetName(
    const CHAR* const type)
{
    const CHAR* name = type;
    CHAR temp[ParameterFileSymbolTableEntry::TYPE_LEN + 1];
    if (PARAMETER_STRCMP(type, ModuleData::GetType(temp, "aecxmtrtablegen")) == 0)
    {
        name = "aecxmtrtablegen";
    }
    return name;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load GeneratorOutputType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool GeneratorOutputType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(output2DWeightID);
    PARAMETER_INITIALIZE(enableGetWeightAverage);
    PARAMETER_INITIALIZE(outputWeightAverageTriggerID);

    SYMBOL_TABLE_ENTRY_READ(entry, result, output2DWeightID, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, enableGetWeightAverage, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, outputWeightAverageTriggerID, alignment)

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load GeneratorSourceType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool GeneratorSourceType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(base2DWeightID);
    PARAMETER_INITIALIZE(statsChannel);
    PARAMETER_INITIALIZE(externData2DWeightID);

    SYMBOL_TABLE_ENTRY_READ(entry, result, base2DWeightID, alignment)

    // Reading String statsChannel from symbol table
    {
        UINT32 count = 0;
        SYMBOL_TABLE_ENTRY_READ(entry, result, count, alignment)
        ParameterFileSymbolTableEntry stringPointerEntryCls;
        ParameterFileSymbolTableEntry* const stringPointerEntry = &stringPointerEntryCls;
        if (result)
        {
            result = entry->Table->ReadPointerEntry(stringPointerEntryCls, entry, alignment);
        }
        SYMBOL_TABLE_ENTRY_READ_STRING(stringPointerEntry, result, statsChannel, count, alignment)
    }
    SYMBOL_TABLE_ENTRY_READ(entry, result, externData2DWeightID, alignment)

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load GeneratorEndLevelDataType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool GeneratorEndLevelDataType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(trigger2);
    PARAMETER_INITIALIZE(triggerData);

    result = trigger2.Load(entry, alignment);
    if (result)
    {
        result = triggerData.Load(entry, alignment);
    }

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load GeneratorTwoLevelTriggerSystemType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool GeneratorTwoLevelTriggerSystemType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(trigger1Lux);
    PARAMETER_INITIALIZE(trigger2Data);

    result = trigger1Lux.Load(entry, alignment);

    // Reading Array trigger2Data from symbol table
    // Do not check result value here because the count value needs to be initialized in this block
    {
        trigger2DataCount = 0;
        SYMBOL_TABLE_ENTRY_READ(entry, result, trigger2DataCount, alignment)
        constexpr const CHAR* const file {__FILE__};
        constexpr INT32 line {LINE_CONST};
        ParameterFileSymbolTableEntry  pointerEntryCls;
        ParameterFileSymbolTableEntry* const pointerEntry = &pointerEntryCls;
        if (result)
        {
            result = entry->Table->ReadPointerEntry(pointerEntryCls, entry, alignment);
        }

        if (result)
        {
            trigger2DataID = pointerEntry->ID;
            DupObjInfo* trigger2DataDupInfo = pointerEntry->GetDupObject(trigger2DataCount, file, line);
            if (trigger2DataDupInfo != nullptr && trigger2DataDupInfo->Object != nullptr)
            {
                trigger2Data = (GeneratorEndLevelDataType*)trigger2DataDupInfo->Object;
                if (trigger2Data == nullptr)
                {
                    if (trigger2DataDupInfo->File != nullptr)
                    {
                        PARAMETER_LOG_ERROR(entry->SetManager, "trigger2Data duplicate found but object is nullptr: %s:%d, RefCount: %d\n",
                            trigger2DataDupInfo->File, trigger2DataDupInfo->Line, trigger2DataDupInfo->RefCount);
                    }
                    else
                    {
                        PARAMETER_LOG_ERROR(entry->SetManager, "trigger2Data duplicate found but Object is nullptr: <nullptr file ptr>:%d, RefCount: %d\n",
                            trigger2DataDupInfo->Line, trigger2DataDupInfo->RefCount);
                    }
                }
            }

            if (trigger2Data == nullptr)
            {
                if (result && trigger2DataCount > 0)
                {
                    trigger2Data = PARAMETER_NEW GeneratorEndLevelDataType[trigger2DataCount];
                    (void)pointerEntry->SetDupObject(trigger2Data, trigger2DataCount, file, line);
                }
                if (!result || trigger2Data == nullptr)
                {
                    if (trigger2DataCount > 0)
                    {
                        PARAMETER_LOG_ERROR(entry->SetManager, "Failed to allocate trigger2Data\n");
                    }
                    trigger2DataCount = 0;
                }
                for (UINT32 i = 0; result && i < trigger2DataCount; i++)
                {
                    result = trigger2Data[i].Load(pointerEntry, alignment);
                }
            }
        }
        if (trigger2Data == nullptr)
        {
            trigger2DataCount = 0;
        }
    }

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load DataDrivenTriggerSystemType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool DataDrivenTriggerSystemType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(trigger1Data);


    // Reading Array trigger1Data from symbol table
    // Do not check result value here because the count value needs to be initialized in this block
    {
        trigger1DataCount = 0;
        SYMBOL_TABLE_ENTRY_READ(entry, result, trigger1DataCount, alignment)
        constexpr const CHAR* const file {__FILE__};
        constexpr INT32 line {LINE_CONST};
        ParameterFileSymbolTableEntry  pointerEntryCls;
        ParameterFileSymbolTableEntry* const pointerEntry = &pointerEntryCls;
        if (result)
        {
            result = entry->Table->ReadPointerEntry(pointerEntryCls, entry, alignment);
        }

        if (result)
        {
            trigger1DataID = pointerEntry->ID;
            DupObjInfo* trigger1DataDupInfo = pointerEntry->GetDupObject(trigger1DataCount, file, line);
            if (trigger1DataDupInfo != nullptr && trigger1DataDupInfo->Object != nullptr)
            {
                trigger1Data = (GeneratorTwoLevelTriggerSystemType*)trigger1DataDupInfo->Object;
                if (trigger1Data == nullptr)
                {
                    if (trigger1DataDupInfo->File != nullptr)
                    {
                        PARAMETER_LOG_ERROR(entry->SetManager, "trigger1Data duplicate found but object is nullptr: %s:%d, RefCount: %d\n",
                            trigger1DataDupInfo->File, trigger1DataDupInfo->Line, trigger1DataDupInfo->RefCount);
                    }
                    else
                    {
                        PARAMETER_LOG_ERROR(entry->SetManager, "trigger1Data duplicate found but Object is nullptr: <nullptr file ptr>:%d, RefCount: %d\n",
                            trigger1DataDupInfo->Line, trigger1DataDupInfo->RefCount);
                    }
                }
            }

            if (trigger1Data == nullptr)
            {
                if (result && trigger1DataCount > 0)
                {
                    trigger1Data = PARAMETER_NEW GeneratorTwoLevelTriggerSystemType[trigger1DataCount];
                    (void)pointerEntry->SetDupObject(trigger1Data, trigger1DataCount, file, line);
                }
                if (!result || trigger1Data == nullptr)
                {
                    if (trigger1DataCount > 0)
                    {
                        PARAMETER_LOG_ERROR(entry->SetManager, "Failed to allocate trigger1Data\n");
                    }
                    trigger1DataCount = 0;
                }
                for (UINT32 i = 0; result && i < trigger1DataCount; i++)
                {
                    result = trigger1Data[i].Load(pointerEntry, alignment);
                }
            }
        }
        if (trigger1Data == nullptr)
        {
            trigger1DataCount = 0;
        }
    }

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load TableGeneratorType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool TableGeneratorType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(enable);
    PARAMETER_INITIALIZE(method);
    PARAMETER_INITIALIZE(input);
    PARAMETER_INITIALIZE(output);
    PARAMETER_INITIALIZE(triggerSystem);

    SYMBOL_TABLE_ENTRY_READ(entry, result, enable, alignment)
    if (result)
    {
        result = aecxmtrtablegen::ReadEnum_GenerationMethodType(entry, method, alignment);
    }
    if (result)
    {
        result = input.Load(entry, alignment);
    }
    if (result)
    {
        result = output.Load(entry, alignment);
    }
    if (result)
    {
        result = triggerSystem.Load(entry, alignment);
    }

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load PrecisionFlashType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool PrecisionFlashType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(enable);
    PARAMETER_INITIALIZE(BackGrdMask);
    PARAMETER_INITIALIZE(ForeGrdMask);
    PARAMETER_INITIALIZE(BackGrdPctDataID);
    PARAMETER_INITIALIZE(BackGrdBiasTblID);
    PARAMETER_INITIALIZE(ForeGrdBiasTblID);
    PARAMETER_INITIALIZE(HighPct);
    PARAMETER_INITIALIZE(BackGrdThld);
    PARAMETER_INITIALIZE(ForeGrdThld);
    PARAMETER_INITIALIZE(DetectionType);
    PARAMETER_INITIALIZE(MinPxlVal);

    SYMBOL_TABLE_ENTRY_READ(entry, result, enable, alignment)
    if (result)
    {
        result = BackGrdMask.Load(entry, alignment);
    }
    if (result)
    {
        result = ForeGrdMask.Load(entry, alignment);
    }
    SYMBOL_TABLE_ENTRY_READ(entry, result, BackGrdPctDataID, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, BackGrdBiasTblID, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, ForeGrdBiasTblID, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, HighPct, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, BackGrdThld, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, ForeGrdThld, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, DetectionType, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, MinPxlVal, alignment)

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load SmartFlashMotionAssistType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool SmartFlashMotionAssistType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(enable);
    PARAMETER_INITIALIZE(motionTh);

    SYMBOL_TABLE_ENTRY_READ(entry, result, enable, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, motionTh, alignment)

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load SmartFlashDepthAssistType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool SmartFlashDepthAssistType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(enable);
    PARAMETER_INITIALIZE(distanceTh);

    SYMBOL_TABLE_ENTRY_READ(entry, result, enable, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, distanceTh, alignment)

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load SmartFlashConfType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool SmartFlashConfType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(enable);
    PARAMETER_INITIALIZE(lumaHighSatTh);

    SYMBOL_TABLE_ENTRY_READ(entry, result, enable, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, lumaHighSatTh, alignment)

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load FlashBiasMtrTblGenCoreConfigType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool FlashBiasMtrTblGenCoreConfigType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(dataBankID);
    PARAMETER_INITIALIZE(baseTableID);
    PARAMETER_INITIALIZE(thresBrightSat);
    PARAMETER_INITIALIZE(flashEstStrength);
    PARAMETER_INITIALIZE(minOffStats);
    PARAMETER_INITIALIZE(kFloorPct);
    PARAMETER_INITIALIZE(satPreventStrength);
    PARAMETER_INITIALIZE(SpeckleScreen);
    PARAMETER_INITIALIZE(flashBiasConf);
    PARAMETER_INITIALIZE(depthAssist);
    PARAMETER_INITIALIZE(motionAssist);

    SYMBOL_TABLE_ENTRY_READ(entry, result, dataBankID, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, baseTableID, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, thresBrightSat, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, flashEstStrength, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, minOffStats, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, kFloorPct, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, satPreventStrength, alignment)
    if (result)
    {
        result = SpeckleScreen.Load(entry, alignment);
    }
    if (result)
    {
        result = flashBiasConf.Load(entry, alignment);
    }
    if (result)
    {
        result = depthAssist.Load(entry, alignment);
    }
    if (result)
    {
        result = motionAssist.Load(entry, alignment);
    }

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load FlashBiasMtrTblGenCoreConfigType_SpeckleScreenStruct
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool FlashBiasMtrTblGenCoreConfigType::SpeckleScreenStruct::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(enable);
    PARAMETER_INITIALIZE(range);

    SYMBOL_TABLE_ENTRY_READ(entry, result, enable, alignment)
    if (result)
    {
        result = range.Load(entry, alignment);
    }

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load MtrStatsSelectionType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool MtrStatsSelectionType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(channel1);
    PARAMETER_INITIALIZE(channel2);
    PARAMETER_INITIALIZE(channel3);
    PARAMETER_INITIALIZE(channel4);
    PARAMETER_INITIALIZE(channel5);
    PARAMETER_INITIALIZE(type);


    // Reading String channel1 from symbol table
    {
        UINT32 count = 0;
        SYMBOL_TABLE_ENTRY_READ(entry, result, count, alignment)
        ParameterFileSymbolTableEntry stringPointerEntryCls;
        ParameterFileSymbolTableEntry* const stringPointerEntry = &stringPointerEntryCls;
        if (result)
        {
            result = entry->Table->ReadPointerEntry(stringPointerEntryCls, entry, alignment);
        }
        SYMBOL_TABLE_ENTRY_READ_STRING(stringPointerEntry, result, channel1, count, alignment)
    }

    // Reading String channel2 from symbol table
    {
        UINT32 count = 0;
        SYMBOL_TABLE_ENTRY_READ(entry, result, count, alignment)
        ParameterFileSymbolTableEntry stringPointerEntryCls;
        ParameterFileSymbolTableEntry* const stringPointerEntry = &stringPointerEntryCls;
        if (result)
        {
            result = entry->Table->ReadPointerEntry(stringPointerEntryCls, entry, alignment);
        }
        SYMBOL_TABLE_ENTRY_READ_STRING(stringPointerEntry, result, channel2, count, alignment)
    }

    // Reading String channel3 from symbol table
    {
        UINT32 count = 0;
        SYMBOL_TABLE_ENTRY_READ(entry, result, count, alignment)
        ParameterFileSymbolTableEntry stringPointerEntryCls;
        ParameterFileSymbolTableEntry* const stringPointerEntry = &stringPointerEntryCls;
        if (result)
        {
            result = entry->Table->ReadPointerEntry(stringPointerEntryCls, entry, alignment);
        }
        SYMBOL_TABLE_ENTRY_READ_STRING(stringPointerEntry, result, channel3, count, alignment)
    }

    // Reading String channel4 from symbol table
    {
        UINT32 count = 0;
        SYMBOL_TABLE_ENTRY_READ(entry, result, count, alignment)
        ParameterFileSymbolTableEntry stringPointerEntryCls;
        ParameterFileSymbolTableEntry* const stringPointerEntry = &stringPointerEntryCls;
        if (result)
        {
            result = entry->Table->ReadPointerEntry(stringPointerEntryCls, entry, alignment);
        }
        SYMBOL_TABLE_ENTRY_READ_STRING(stringPointerEntry, result, channel4, count, alignment)
    }

    // Reading String channel5 from symbol table
    {
        UINT32 count = 0;
        SYMBOL_TABLE_ENTRY_READ(entry, result, count, alignment)
        ParameterFileSymbolTableEntry stringPointerEntryCls;
        ParameterFileSymbolTableEntry* const stringPointerEntry = &stringPointerEntryCls;
        if (result)
        {
            result = entry->Table->ReadPointerEntry(stringPointerEntryCls, entry, alignment);
        }
        SYMBOL_TABLE_ENTRY_READ_STRING(stringPointerEntry, result, channel5, count, alignment)
    }
    if (result)
    {
        result = aecxglobalelements::ReadEnum_AECXStatsType(entry, type, alignment);
    }

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load FlashBiasMtrTblGenConfigType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool FlashBiasMtrTblGenConfigType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(statsSelection);
    PARAMETER_INITIALIZE(mtrTblConfig);

    result = statsSelection.Load(entry, alignment);
    if (result)
    {
        result = mtrTblConfig.Load(entry, alignment);
    }

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load AECXMtrTableGenType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool AECXMtrTableGenType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(module_version);
    PARAMETER_INITIALIZE(parameter_version);
    PARAMETER_INITIALIZE(moduleID);
    PARAMETER_INITIALIZE(flashBiasMetTblGen);
    PARAMETER_INITIALIZE(PrecisionFlashTblGen);
    PARAMETER_INITIALIZE(tableGenerator);

    result = module_version.Load(entry, alignment);
    if (result)
    {
        result = parameter_version.Load(entry, alignment);
    }
    if (result)
    {
        result = aecxglobalelements::ReadEnum_AECXModuleIDType(entry, moduleID, alignment);
    }
    if (result)
    {
        result = flashBiasMetTblGen.Load(entry, alignment);
    }
    if (result)
    {
        result = PrecisionFlashTblGen.Load(entry, alignment);
    }

    // Reading Array tableGenerator from symbol table
    // Do not check result value here because the count value needs to be initialized in this block
    {
        tableGeneratorCount = 0;
        SYMBOL_TABLE_ENTRY_READ(entry, result, tableGeneratorCount, alignment)
        constexpr const CHAR* const file {__FILE__};
        constexpr INT32 line {LINE_CONST};
        ParameterFileSymbolTableEntry  pointerEntryCls;
        ParameterFileSymbolTableEntry* const pointerEntry = &pointerEntryCls;
        if (result)
        {
            result = entry->Table->ReadPointerEntry(pointerEntryCls, entry, alignment);
        }

        if (result)
        {
            tableGeneratorID = pointerEntry->ID;
            DupObjInfo* tableGeneratorDupInfo = pointerEntry->GetDupObject(tableGeneratorCount, file, line);
            if (tableGeneratorDupInfo != nullptr && tableGeneratorDupInfo->Object != nullptr)
            {
                tableGenerator = (TableGeneratorType*)tableGeneratorDupInfo->Object;
                if (tableGenerator == nullptr)
                {
                    if (tableGeneratorDupInfo->File != nullptr)
                    {
                        PARAMETER_LOG_ERROR(entry->SetManager, "tableGenerator duplicate found but object is nullptr: %s:%d, RefCount: %d\n",
                            tableGeneratorDupInfo->File, tableGeneratorDupInfo->Line, tableGeneratorDupInfo->RefCount);
                    }
                    else
                    {
                        PARAMETER_LOG_ERROR(entry->SetManager, "tableGenerator duplicate found but Object is nullptr: <nullptr file ptr>:%d, RefCount: %d\n",
                            tableGeneratorDupInfo->Line, tableGeneratorDupInfo->RefCount);
                    }
                }
            }

            if (tableGenerator == nullptr)
            {
                if (result && tableGeneratorCount > 0)
                {
                    tableGenerator = PARAMETER_NEW TableGeneratorType[tableGeneratorCount];
                    (void)pointerEntry->SetDupObject(tableGenerator, tableGeneratorCount, file, line);
                }
                if (!result || tableGenerator == nullptr)
                {
                    if (tableGeneratorCount > 0)
                    {
                        PARAMETER_LOG_ERROR(entry->SetManager, "Failed to allocate tableGenerator\n");
                    }
                    tableGeneratorCount = 0;
                }
                for (UINT32 i = 0; result && i < tableGeneratorCount; i++)
                {
                    result = tableGenerator[i].Load(pointerEntry, alignment);
                }
            }
        }
        if (tableGenerator == nullptr)
        {
            tableGeneratorCount = 0;
        }
    }

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load module_versionStruct
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool AECXMtrTableGenType::module_versionStruct::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(major_revision);
    PARAMETER_INITIALIZE(minor_revision);
    PARAMETER_INITIALIZE(incr_revision);

    SYMBOL_TABLE_ENTRY_READ(entry, result, major_revision, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, minor_revision, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, incr_revision, alignment)

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load parameter_versionStruct
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool AECXMtrTableGenType::parameter_versionStruct::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(revision);


    // Reading String revision from symbol table
    {
        UINT32 count = 0;
        SYMBOL_TABLE_ENTRY_READ(entry, result, count, alignment)
        ParameterFileSymbolTableEntry stringPointerEntryCls;
        ParameterFileSymbolTableEntry* const stringPointerEntry = &stringPointerEntryCls;
        if (result)
        {
            result = entry->Table->ReadPointerEntry(stringPointerEntryCls, entry, alignment);
        }
        SYMBOL_TABLE_ENTRY_READ_STRING(stringPointerEntry, result, revision, count, alignment)
    }

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Unload GeneratorSourceType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void GeneratorSourceType::Unload(ParameterFileSymbolTable* const __table)
{
    if (__table != nullptr && __table->ReleaseDupObject(statsChannel))
    {
        PARAMETER_DELETE[] statsChannel;
    }
    statsChannel = nullptr;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Unload GeneratorTwoLevelTriggerSystemType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void GeneratorTwoLevelTriggerSystemType::Unload(ParameterFileSymbolTable* const __table)
{
    if (__table != nullptr && __table->ReleaseDupObject(trigger2Data))
    {
        PARAMETER_DELETE[] trigger2Data;
    }
    trigger2Data = nullptr;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Unload DataDrivenTriggerSystemType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void DataDrivenTriggerSystemType::Unload(ParameterFileSymbolTable* const __table)
{
    for (UINT32 i = 0; i < trigger1DataCount; i++)
    {
        trigger1Data[i].Unload(__table);
    }
    if (__table != nullptr && __table->ReleaseDupObject(trigger1Data))
    {
        PARAMETER_DELETE[] trigger1Data;
    }
    trigger1Data = nullptr;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Unload TableGeneratorType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void TableGeneratorType::Unload(ParameterFileSymbolTable* const __table)
{
    input.Unload(__table);
    triggerSystem.Unload(__table);
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Unload PrecisionFlashType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void PrecisionFlashType::Unload(ParameterFileSymbolTable* const __table)
{
    BackGrdMask.Unload(__table);
    ForeGrdMask.Unload(__table);
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Unload MtrStatsSelectionType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void MtrStatsSelectionType::Unload(ParameterFileSymbolTable* const __table)
{
    if (__table != nullptr && __table->ReleaseDupObject(channel1))
    {
        PARAMETER_DELETE[] channel1;
    }
    channel1 = nullptr;
    if (__table != nullptr && __table->ReleaseDupObject(channel2))
    {
        PARAMETER_DELETE[] channel2;
    }
    channel2 = nullptr;
    if (__table != nullptr && __table->ReleaseDupObject(channel3))
    {
        PARAMETER_DELETE[] channel3;
    }
    channel3 = nullptr;
    if (__table != nullptr && __table->ReleaseDupObject(channel4))
    {
        PARAMETER_DELETE[] channel4;
    }
    channel4 = nullptr;
    if (__table != nullptr && __table->ReleaseDupObject(channel5))
    {
        PARAMETER_DELETE[] channel5;
    }
    channel5 = nullptr;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Unload FlashBiasMtrTblGenConfigType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void FlashBiasMtrTblGenConfigType::Unload(ParameterFileSymbolTable* const __table)
{
    statsSelection.Unload(__table);
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Unload AECXMtrTableGenType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void AECXMtrTableGenType::Unload(ParameterFileSymbolTable* const __table)
{
    parameter_version.Unload(__table);
    flashBiasMetTblGen.Unload(__table);
    PrecisionFlashTblGen.Unload(__table);
    for (UINT32 i = 0; i < tableGeneratorCount; i++)
    {
        tableGenerator[i].Unload(__table);
    }
    if (__table != nullptr && __table->ReleaseDupObject(tableGenerator))
    {
        PARAMETER_DELETE[] tableGenerator;
    }
    tableGenerator = nullptr;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Unload parameter_versionStruct
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void AECXMtrTableGenType::parameter_versionStruct::Unload(ParameterFileSymbolTable* const __table)
{
    if (__table != nullptr && __table->ReleaseDupObject(revision))
    {
        PARAMETER_DELETE[] revision;
    }
    revision = nullptr;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Release the ParameterModule object
/// Requires that this object was created via a ParameterSetManager::GetModule call
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void AECXMtrTableGenType::Release()
{
    ((AECXMtrTableGenTypeClass*)this)->Release();
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Returns the ParameterModule::Modified value
/// The Modified value is incremented when the module's data or pointer values change
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
UINT32 AECXMtrTableGenType::GetModified()
{
    return ((AECXMtrTableGenTypeClass*)this)->Modified;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Create module, and return a new object
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
ParameterModule* AECXMtrTableGenTypeClass::Create(
    ModuleData*    moduleData,
    DefaultModule* const defModule) const
{
    AECXMtrTableGenTypeClass* cls = nullptr;

    if (PARAMETER_STRCMP(Type, moduleData->Type) == 0 && Version.Value == moduleData->Version.Value)
    {
        const UINT32 id = moduleData->DuplicateID > 0 ? moduleData->DuplicateID : moduleData->ID;

        ParameterModule* const module = defModule->Find(id);
        if (module != nullptr)
        {
            cls = (AECXMtrTableGenTypeClass*)module;
        }
        else
        {
            cls = PARAMETER_NEW AECXMtrTableGenTypeClass(GetName(moduleData->Type), moduleData);
            cls->SymbolTableID = id;
            defModule->AddModule((ParameterModule*)cls);
        }
    }
    else if (Version.Value != moduleData->Version.Value)
    {
        PARAMETER_LOG_ERROR(moduleData->SetManager, "Unable to create AECXMtrTableGenTypeClass, binary version (%lld) does not match source version (%lld)\n",
            moduleData->Version.Value, Version.Value);
    }
    else
    {
        PARAMETER_LOG_ERROR(moduleData->SetManager, "Unable to create AECXMtrTableGenTypeClass, binary name (%s) does not match source name (%s)\n",
            moduleData->Type, Type);
    }

    return (ParameterModule*)cls;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load module data, return true is successful
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool AECXMtrTableGenTypeClass::LoadModule(
    ParameterFileSymbolTable* const table)
{
    bool result = true;

    if (!Loaded)
    {
        BYTE const alignment = table->Alignment;
        AECXMtrTableGenTypeClass* const cls = this;

        ParameterFileSymbolTableEntry  entryObj;
        ParameterFileSymbolTableEntry* const entry = &entryObj;
        // With EzTune enabled, the unused upper byte of SymbolTableID value can change, so clear it
        result = table->Find(entryObj, SymbolTableID & 0x00ffffff);

        if (!result)
        {
            PARAMETER_LOG_ERROR(entry->SetManager, "AECXMtrTableGenTypeClass::LoadModule Failed to find module ID (%d) in Symbol Table\n", SymbolTableID);
        }

        if (result)
        {
            result = cls->Load(entry, alignment);
        }
        Modified++;
        Loaded = true;
    }

    if (!result)
    {
        /// Module failed to fully load, unload it
        UnloadModule();
    }

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Unload module data
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void AECXMtrTableGenTypeClass::UnloadModule()
{
    if (Loaded)
    {
        if (Data != nullptr && Data->SymbolTable != nullptr)
        {
            Unload(Data->SymbolTable);
        }
        else
        {
            PARAMETER_LOG_ERROR(Data != nullptr ? Data->SetManager : nullptr, "UnloadModule %s called with nullptr "
                "Data->SymbolTable object\n", Name);
            Unload(nullptr);
        }
        Loaded = false;
    }
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// /// Release the ParameterModule object
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void AECXMtrTableGenTypeClass::Release()
{
    ParameterModule::Release();
}

AECXMTRTABLEGEN_NAMESPACE_END
