类 CaptchaUtils
- java.lang.Object
-
- ai.yue.library.web.util.CaptchaUtils
-
public class CaptchaUtils extends Object
验证码工具类,用于创建验证码图片与验证验证码若需要分布式验证,推荐使用 yue-library-data-redis 模块 User 类所提供的 getCaptchaImage() 方法
- 从以下版本开始:
- 2018年4月3日
- 作者:
- ylyue
-
-
字段概要
字段 修饰符和类型 字段 说明 static StringCAPTCHA_KEYCaptcha Keystatic StringCAPTCHA_REDIS_PREFIXCaptcha Redis 前缀
-
构造器概要
构造器 构造器 说明 CaptchaUtils()
-
-
-
方法详细资料
-
createCaptchaImage
public static CaptchaVO createCaptchaImage(CaptchaIPO captchaIPO)
创建验证码- 参数:
captchaIPO- 验证码IPO- 返回:
- 验证码VO
-
isValidateCaptcha
public static boolean isValidateCaptcha(String captcha)
验证-验证码- 参数:
captcha- 验证码- 返回:
- 是否正确
-
-