package com.everyday.word.config;
|
|
/**
|
* @author hxh
|
* @title: RedisKeyEnum
|
* @description: Redis的键枚举
|
* @date 2025/2/11 17:08
|
*/
|
public enum RedisKeyEnum {
|
emptyKey("", "空值-key外部空值"),
|
SMS("sms-", "短信"),
|
SMSVCode("smscode-", "短信验证码");
|
|
private final String key;
|
private final String desc;
|
|
private RedisKeyEnum(String key, String desc) {
|
this.key = key;
|
this.desc = desc;
|
}
|
|
public String getDesc() {
|
return desc;
|
}
|
|
public String getKey() {
|
return key;
|
}
|
|
public static String getRedisKey(RedisKeyEnum keyEnum, String value) {
|
return keyEnum.getKey() + value;
|
}
|
|
}
|