public class DefaultCaptchaManager extends Object implements CaptchaManager, org.springframework.beans.factory.InitializingBean
| Constructor and Description |
|---|
DefaultCaptchaManager() |
| Modifier and Type | Method and Description |
|---|---|
void |
afterPropertiesSet() |
void |
disableChar()
Disable to generate the char captcha
|
void |
disableNumber()
Disable to generate the number captcha
|
void |
enableChar()
Enable to generate the char captcha
|
void |
enableNumber()
Enable to generate the number captcha
|
Captcha |
generate() |
void |
setCaptchaProvider(CaptchaProvider captchaProvider) |
void |
setCaptchaTimeout(long timeout) |
void |
setLength(int length) |
void |
verify(CaptchaVerifyRequest request) |
public void setCaptchaProvider(CaptchaProvider captchaProvider)
public void setLength(int length)
setLength in interface CaptchaOptionslength - the length of the captcha, must be the range of 4~12public void enableNumber()
CaptchaOptionsenableNumber in interface CaptchaOptionspublic void enableChar()
CaptchaOptionsenableChar in interface CaptchaOptionspublic void disableNumber()
CaptchaOptionsdisableNumber in interface CaptchaOptionspublic void disableChar()
CaptchaOptionsdisableChar in interface CaptchaOptionspublic void setCaptchaTimeout(long timeout)
setCaptchaTimeout in interface CaptchaOptionstimeout - milli seconds , must be the range of 30s ~ 10*60spublic Captcha generate()
generate in interface CaptchaManagerpublic void verify(CaptchaVerifyRequest request)
verify in interface CaptchaManagerpublic void afterPropertiesSet()
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBeanCopyright © 2018. All rights reserved.