// ================================================================================
// Code generated and maintained by GoFrame CLI tool. DO NOT EDIT.
// You can delete these comments if you wish manually maintain this interface file.
// ================================================================================

package service

import (
	"context"
	"kami/internal/consts"
	"kami/internal/model"

	"github.com/gogf/gf/v2/database/gdb"
)

type (
	ISysConfigDict interface {
		// InitAESKeyAndIV 初始化 AES 密钥和 IV，在应用启动时调用
		InitAESKeyAndIV(ctx context.Context) (err error)
		// GetAESKey 从 Redis 获取 AES 加密参数（密钥和初始化向量）
		GetAESKey(ctx context.Context) (params *model.AESEncryptionParams, err error)
		// GetAESKeyBytes 从 Redis 获取 AES 加密参数（密钥和初始化向量）
		GetAESKeyBytes(ctx context.Context) (params *model.AESEncryptionParamsBytes, err error)
		// GetIsStealAppleCard 判断是否偷取苹果卡
		GetIsStealAppleCard(ctx context.Context) (isSteal bool)
		// SetIsStealAppleCard 设置是否偷取苹果卡
		SetIsStealAppleCard(ctx context.Context, isSteal bool) (err error)
		// GetMerchantStealRuleStatus 判断是否偷取苹果卡
		GetMerchantStealRuleStatus(ctx context.Context) (isSteal bool)
		// SetMerchantStealRuleStatus 设置是否偷卡
		SetMerchantStealRuleStatus(ctx context.Context, isSteal bool) (err error)
		// GetIsStealMerchantCard 判断当前是否偷取商户卡
		GetIsStealMerchantCard(ctx context.Context) (isSteal bool)
		// SetIsStealMerchantCard 设置是否偷取苹果卡
		SetIsStealMerchantCard(ctx context.Context, isSteal bool) (err error)
		// SetIsAllowRedeemCardDifferentAmount 京东拿卡策略，金额异议是否兑换
		SetIsAllowRedeemCardDifferentAmount(ctx context.Context, category consts.CardRedeemAccountCategory, isAllow bool) (err error)
		GetIsAllowRedeemCardDifferentAmount(ctx context.Context, category consts.CardRedeemAccountCategory) (isAllow bool, err error)
		// SetIsAllowRedeemCardMaxCount 京东拿卡策略，金额异议是否兑换
		SetIsAllowRedeemCardMaxCount(ctx context.Context, category consts.CardRedeemAccountCategory, amount float64) (err error)
		// GetIsAllowRedeemCardMaxCount 设置账号最大充值次数
		GetIsAllowRedeemCardMaxCount(ctx context.Context, category consts.CardRedeemAccountCategory) (amount float64, err error)
		// GetRedeemCardSucceedCallbackIsAllow 成功的金额异议是否允许回调
		GetRedeemCardSucceedCallbackIsAllow(ctx context.Context, category consts.CardRedeemAccountCategory) (isAllow bool)
		// SetRedeemCardSucceedCallbackIsAllow 京东拿卡策略，金额异议是否兑换
		SetRedeemCardSucceedCallbackIsAllow(ctx context.Context, category consts.CardRedeemAccountCategory, isAllow bool) (err error)
		// GetRedeemCardFailCallbackIsAllow 成功的金额异议是否允许回调
		GetRedeemCardFailCallbackIsAllow(ctx context.Context, category consts.CardRedeemAccountCategory) (isAllow bool)
		// SetRedeemCardFailCallbackIsAllow 京东拿卡策略，金额异议是否兑换
		SetRedeemCardFailCallbackIsAllow(ctx context.Context, category consts.CardRedeemAccountCategory, isAllow bool) (err error)
		// GetRedeemCardMinAmount 获取最小充值金额
		GetRedeemCardMinAmount(ctx context.Context, category consts.CardRedeemAccountCategory) (amount int64)
		// SetRedeemCardMinAmount 设置最小充值金额
		SetRedeemCardMinAmount(ctx context.Context, category consts.CardRedeemAccountCategory, amount int64) (err error)
		// SetRedeemCardCompensatedAutoCallback 补卡是否自动回调
		SetRedeemCardCompensatedAutoCallback(ctx context.Context, category consts.CardRedeemAccountCategory, isAllow bool) (err error)
		// GetRedeemCardCompensatedAutoCallback 补卡是否自动回调
		GetRedeemCardCompensatedAutoCallback(ctx context.Context, category consts.CardRedeemAccountCategory) (isAllow bool)
		// GetRedeemCardRate 设置单位内充值速率
		GetRedeemCardRate(ctx context.Context, category consts.CardRedeemAccountCategory) (rate int)
		GetMaxAccountRedeemCount(ctx context.Context, category consts.CardRedeemAccountCategory) (count int)
		SetMaxAccountRedeemCount(ctx context.Context, category consts.CardRedeemAccountCategory, count int) (isAllow bool)
		// SetIsAllowedRepeated 获取是否允许重复上传
		SetIsAllowedRepeated(ctx context.Context, category consts.CardRedeemAccountCategory, isAllow bool) (err error)
		// GetIsAllowedRepeated 获取是否允许重复上传
		GetIsAllowedRepeated(ctx context.Context, category consts.CardRedeemAccountCategory) (isAllow bool)
		SetRedeemCardRate(ctx context.Context, category consts.CardRedeemAccountCategory, rate int)
		// SetRedeemScheduleStrategy 设置调度策略
		SetRedeemScheduleStrategy(ctx context.Context, category consts.CardRedeemAccountCategory, strategy consts.RedeemCardScheduleStrategyType, tx gdb.TX) (err error)
		// GetRedeemScheduleStrategy 获取调度策略
		GetRedeemScheduleStrategy(ctx context.Context, category consts.CardRedeemAccountCategory, tx gdb.TX) (strategy consts.RedeemCardScheduleStrategyType, err error)
	}
)

var (
	localSysConfigDict ISysConfigDict
)

func SysConfigDict() ISysConfigDict {
	if localSysConfigDict == nil {
		panic("implement not found for interface ISysConfigDict, forgot register?")
	}
	return localSysConfigDict
}

func RegisterSysConfigDict(i ISysConfigDict) {
	localSysConfigDict = i
}
