// This file is generated by kconfig_compiler_kf6 from easyeffects_db_speex.kcfg.
// All changes you do to this file will be lost.
#ifndef DBSPEEX_H
#define DBSPEEX_H

#include "kconfig_base_ee.hpp"

#include <kconfigskeleton.h>
#include <QCoreApplication>
#include <QDebug>
#include <qqmlintegration.h>

class DbSpeex : public KConfigBaseEE
{
  Q_OBJECT
  QML_ELEMENT
  QML_UNCREATABLE("")
  public:

    DbSpeex( const QString & masterGroup, const QString & instanceIndex );
    ~DbSpeex() override;

    /**
      Set bypass
    */
    void setBypass( bool v )
    {
      if (v != mBypass && !isBypassImmutable()) {
        mBypass = v;
        Q_EMIT bypassChanged();
      }
    }

    Q_PROPERTY(bool bypass READ bypass WRITE setBypass NOTIFY bypassChanged)
    Q_PROPERTY(bool isBypassImmutable READ isBypassImmutable CONSTANT)
    Q_PROPERTY(bool defaultBypassValue READ defaultBypassValue CONSTANT)
    /**
      Get bypass
    */
    bool bypass() const
    {
      return mBypass;
    }

    /**
      Is bypass Immutable
    */
    bool isBypassImmutable() const
    {
      return isImmutable( QStringLiteral( "bypass" ) );
    }

    /**
      Get bypass default value
    */
    bool defaultBypassValue() const
    {
        return defaultBypassValue_helper();
    }

    /**
      Set inputGain
    */
    void setInputGain( double v )
    {
      if (v < -36)
      {
        qDebug() << "setInputGain: value " << v << " is less than the minimum value of -36";
        v = -36;
      }

      if (v > 36)
      {
        qDebug() << "setInputGain: value " << v << " is greater than the maximum value of 36";
        v = 36;
      }

      if (v != mInputGain && !isInputGainImmutable()) {
        mInputGain = v;
        Q_EMIT inputGainChanged();
      }
    }

    Q_PROPERTY(double inputGain READ inputGain WRITE setInputGain NOTIFY inputGainChanged)
    Q_PROPERTY(bool isInputGainImmutable READ isInputGainImmutable CONSTANT)
    Q_PROPERTY(double defaultInputGainValue READ defaultInputGainValue CONSTANT)
    /**
      Get inputGain
    */
    double inputGain() const
    {
      return mInputGain;
    }

    /**
      Is inputGain Immutable
    */
    bool isInputGainImmutable() const
    {
      return isImmutable( QStringLiteral( "inputGain" ) );
    }

    /**
      Get inputGain default value
    */
    double defaultInputGainValue() const
    {
        return defaultInputGainValue_helper();
    }

    /**
      Set outputGain
    */
    void setOutputGain( double v )
    {
      if (v < -36)
      {
        qDebug() << "setOutputGain: value " << v << " is less than the minimum value of -36";
        v = -36;
      }

      if (v > 36)
      {
        qDebug() << "setOutputGain: value " << v << " is greater than the maximum value of 36";
        v = 36;
      }

      if (v != mOutputGain && !isOutputGainImmutable()) {
        mOutputGain = v;
        Q_EMIT outputGainChanged();
      }
    }

    Q_PROPERTY(double outputGain READ outputGain WRITE setOutputGain NOTIFY outputGainChanged)
    Q_PROPERTY(bool isOutputGainImmutable READ isOutputGainImmutable CONSTANT)
    Q_PROPERTY(double defaultOutputGainValue READ defaultOutputGainValue CONSTANT)
    /**
      Get outputGain
    */
    double outputGain() const
    {
      return mOutputGain;
    }

    /**
      Is outputGain Immutable
    */
    bool isOutputGainImmutable() const
    {
      return isImmutable( QStringLiteral( "outputGain" ) );
    }

    /**
      Get outputGain default value
    */
    double defaultOutputGainValue() const
    {
        return defaultOutputGainValue_helper();
    }

    /**
      Set enableDenoise
    */
    void setEnableDenoise( bool v )
    {
      if (v != mEnableDenoise && !isEnableDenoiseImmutable()) {
        mEnableDenoise = v;
        Q_EMIT enableDenoiseChanged();
      }
    }

    Q_PROPERTY(bool enableDenoise READ enableDenoise WRITE setEnableDenoise NOTIFY enableDenoiseChanged)
    Q_PROPERTY(bool isEnableDenoiseImmutable READ isEnableDenoiseImmutable CONSTANT)
    Q_PROPERTY(bool defaultEnableDenoiseValue READ defaultEnableDenoiseValue CONSTANT)
    /**
      Get enableDenoise
    */
    bool enableDenoise() const
    {
      return mEnableDenoise;
    }

    /**
      Is enableDenoise Immutable
    */
    bool isEnableDenoiseImmutable() const
    {
      return isImmutable( QStringLiteral( "enableDenoise" ) );
    }

    /**
      Get enableDenoise default value
    */
    bool defaultEnableDenoiseValue() const
    {
        return defaultEnableDenoiseValue_helper();
    }

    /**
      Set noiseSuppression
    */
    void setNoiseSuppression( int v )
    {
      if (v < -100)
      {
        qDebug() << "setNoiseSuppression: value " << v << " is less than the minimum value of -100";
        v = -100;
      }

      if (v > -1)
      {
        qDebug() << "setNoiseSuppression: value " << v << " is greater than the maximum value of -1";
        v = -1;
      }

      if (v != mNoiseSuppression && !isNoiseSuppressionImmutable()) {
        mNoiseSuppression = v;
        Q_EMIT noiseSuppressionChanged();
      }
    }

    Q_PROPERTY(int noiseSuppression READ noiseSuppression WRITE setNoiseSuppression NOTIFY noiseSuppressionChanged)
    Q_PROPERTY(bool isNoiseSuppressionImmutable READ isNoiseSuppressionImmutable CONSTANT)
    Q_PROPERTY(int defaultNoiseSuppressionValue READ defaultNoiseSuppressionValue CONSTANT)
    /**
      Get noiseSuppression
    */
    int noiseSuppression() const
    {
      return mNoiseSuppression;
    }

    /**
      Is noiseSuppression Immutable
    */
    bool isNoiseSuppressionImmutable() const
    {
      return isImmutable( QStringLiteral( "noiseSuppression" ) );
    }

    /**
      Get noiseSuppression default value
    */
    int defaultNoiseSuppressionValue() const
    {
        return defaultNoiseSuppressionValue_helper();
    }

    /**
      Set enableAgc
    */
    void setEnableAgc( bool v )
    {
      if (v != mEnableAgc && !isEnableAgcImmutable()) {
        mEnableAgc = v;
        Q_EMIT enableAgcChanged();
      }
    }

    Q_PROPERTY(bool enableAgc READ enableAgc WRITE setEnableAgc NOTIFY enableAgcChanged)
    Q_PROPERTY(bool isEnableAgcImmutable READ isEnableAgcImmutable CONSTANT)
    Q_PROPERTY(bool defaultEnableAgcValue READ defaultEnableAgcValue CONSTANT)
    /**
      Get enableAgc
    */
    bool enableAgc() const
    {
      return mEnableAgc;
    }

    /**
      Is enableAgc Immutable
    */
    bool isEnableAgcImmutable() const
    {
      return isImmutable( QStringLiteral( "enableAgc" ) );
    }

    /**
      Get enableAgc default value
    */
    bool defaultEnableAgcValue() const
    {
        return defaultEnableAgcValue_helper();
    }

    /**
      Set enableVad
    */
    void setEnableVad( bool v )
    {
      if (v != mEnableVad && !isEnableVadImmutable()) {
        mEnableVad = v;
        Q_EMIT enableVadChanged();
      }
    }

    Q_PROPERTY(bool enableVad READ enableVad WRITE setEnableVad NOTIFY enableVadChanged)
    Q_PROPERTY(bool isEnableVadImmutable READ isEnableVadImmutable CONSTANT)
    Q_PROPERTY(bool defaultEnableVadValue READ defaultEnableVadValue CONSTANT)
    /**
      Get enableVad
    */
    bool enableVad() const
    {
      return mEnableVad;
    }

    /**
      Is enableVad Immutable
    */
    bool isEnableVadImmutable() const
    {
      return isImmutable( QStringLiteral( "enableVad" ) );
    }

    /**
      Get enableVad default value
    */
    bool defaultEnableVadValue() const
    {
        return defaultEnableVadValue_helper();
    }

    /**
      Set vadProbabilityStart
    */
    void setVadProbabilityStart( int v )
    {
      if (v < 0)
      {
        qDebug() << "setVadProbabilityStart: value " << v << " is less than the minimum value of 0";
        v = 0;
      }

      if (v > 100)
      {
        qDebug() << "setVadProbabilityStart: value " << v << " is greater than the maximum value of 100";
        v = 100;
      }

      if (v != mVadProbabilityStart && !isVadProbabilityStartImmutable()) {
        mVadProbabilityStart = v;
        Q_EMIT vadProbabilityStartChanged();
      }
    }

    Q_PROPERTY(int vadProbabilityStart READ vadProbabilityStart WRITE setVadProbabilityStart NOTIFY vadProbabilityStartChanged)
    Q_PROPERTY(bool isVadProbabilityStartImmutable READ isVadProbabilityStartImmutable CONSTANT)
    Q_PROPERTY(int defaultVadProbabilityStartValue READ defaultVadProbabilityStartValue CONSTANT)
    /**
      Get vadProbabilityStart
    */
    int vadProbabilityStart() const
    {
      return mVadProbabilityStart;
    }

    /**
      Is vadProbabilityStart Immutable
    */
    bool isVadProbabilityStartImmutable() const
    {
      return isImmutable( QStringLiteral( "vadProbabilityStart" ) );
    }

    /**
      Get vadProbabilityStart default value
    */
    int defaultVadProbabilityStartValue() const
    {
        return defaultVadProbabilityStartValue_helper();
    }

    /**
      Set vadProbabilityContinue
    */
    void setVadProbabilityContinue( int v )
    {
      if (v < 0)
      {
        qDebug() << "setVadProbabilityContinue: value " << v << " is less than the minimum value of 0";
        v = 0;
      }

      if (v > 100)
      {
        qDebug() << "setVadProbabilityContinue: value " << v << " is greater than the maximum value of 100";
        v = 100;
      }

      if (v != mVadProbabilityContinue && !isVadProbabilityContinueImmutable()) {
        mVadProbabilityContinue = v;
        Q_EMIT vadProbabilityContinueChanged();
      }
    }

    Q_PROPERTY(int vadProbabilityContinue READ vadProbabilityContinue WRITE setVadProbabilityContinue NOTIFY vadProbabilityContinueChanged)
    Q_PROPERTY(bool isVadProbabilityContinueImmutable READ isVadProbabilityContinueImmutable CONSTANT)
    Q_PROPERTY(int defaultVadProbabilityContinueValue READ defaultVadProbabilityContinueValue CONSTANT)
    /**
      Get vadProbabilityContinue
    */
    int vadProbabilityContinue() const
    {
      return mVadProbabilityContinue;
    }

    /**
      Is vadProbabilityContinue Immutable
    */
    bool isVadProbabilityContinueImmutable() const
    {
      return isImmutable( QStringLiteral( "vadProbabilityContinue" ) );
    }

    /**
      Get vadProbabilityContinue default value
    */
    int defaultVadProbabilityContinueValue() const
    {
        return defaultVadProbabilityContinueValue_helper();
    }

    /**
      Set enableDereverb
    */
    void setEnableDereverb( bool v )
    {
      if (v != mEnableDereverb && !isEnableDereverbImmutable()) {
        mEnableDereverb = v;
        Q_EMIT enableDereverbChanged();
      }
    }

    Q_PROPERTY(bool enableDereverb READ enableDereverb WRITE setEnableDereverb NOTIFY enableDereverbChanged)
    Q_PROPERTY(bool isEnableDereverbImmutable READ isEnableDereverbImmutable CONSTANT)
    Q_PROPERTY(bool defaultEnableDereverbValue READ defaultEnableDereverbValue CONSTANT)
    /**
      Get enableDereverb
    */
    bool enableDereverb() const
    {
      return mEnableDereverb;
    }

    /**
      Is enableDereverb Immutable
    */
    bool isEnableDereverbImmutable() const
    {
      return isImmutable( QStringLiteral( "enableDereverb" ) );
    }

    /**
      Get enableDereverb default value
    */
    bool defaultEnableDereverbValue() const
    {
        return defaultEnableDereverbValue_helper();
    }


    enum {
      signalBypassChanged = 1,
      signalInputGainChanged = 2,
      signalOutputGainChanged = 3,
      signalEnableDenoiseChanged = 4,
      signalNoiseSuppressionChanged = 5,
      signalEnableAgcChanged = 6,
      signalEnableVadChanged = 7,
      signalVadProbabilityStartChanged = 8,
      signalVadProbabilityContinueChanged = 9,
      signalEnableDereverbChanged = 10
    };

  Q_SIGNALS:
    void bypassChanged();

    void inputGainChanged();

    void outputGainChanged();

    void enableDenoiseChanged();

    void noiseSuppressionChanged();

    void enableAgcChanged();

    void enableVadChanged();

    void vadProbabilityStartChanged();

    void vadProbabilityContinueChanged();

    void enableDereverbChanged();

  private:
    void itemChanged(quint64 signalFlag);

  protected:
    QString mParammasterGroup;
    QString mParaminstanceIndex;

    // Speex#$(instanceIndex)
    bool mBypass;
    bool defaultBypassValue_helper() const;
    double mInputGain;
    double defaultInputGainValue_helper() const;
    double mOutputGain;
    double defaultOutputGainValue_helper() const;
    bool mEnableDenoise;
    bool defaultEnableDenoiseValue_helper() const;
    int mNoiseSuppression;
    int defaultNoiseSuppressionValue_helper() const;
    bool mEnableAgc;
    bool defaultEnableAgcValue_helper() const;
    bool mEnableVad;
    bool defaultEnableVadValue_helper() const;
    int mVadProbabilityStart;
    int defaultVadProbabilityStartValue_helper() const;
    int mVadProbabilityContinue;
    int defaultVadProbabilityContinueValue_helper() const;
    bool mEnableDereverb;
    bool defaultEnableDereverbValue_helper() const;
};

#endif

