public class CaptchaUtil extends Object
| 构造器和说明 |
|---|
CaptchaUtil() |
| 限定符和类型 | 方法和说明 |
|---|---|
static void |
clear(javax.servlet.http.HttpServletRequest request)
清除session中的验证码
|
static void |
out(Captcha captcha,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
输出验证码
|
static void |
out(Font font,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
输出验证码
|
static void |
out(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
输出验证码
|
static void |
out(int len,
Font font,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
输出验证码
|
static void |
out(int len,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
输出验证码
|
static void |
out(int width,
int height,
int len,
Font font,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
输出验证码
|
static void |
out(int width,
int height,
int len,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
输出验证码
|
static void |
setHeader(javax.servlet.http.HttpServletResponse response)
设置相应头
|
static boolean |
ver(String code,
javax.servlet.http.HttpServletRequest request)
验证验证码
|
public static void out(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws IOException
request - HttpServletRequestresponse - HttpServletResponseIOException - IO异常public static void out(int len,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws IOException
len - 长度request - HttpServletRequestresponse - HttpServletResponseIOException - IO异常public static void out(int width,
int height,
int len,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws IOException
width - 宽度height - 高度len - 长度request - HttpServletRequestresponse - HttpServletResponseIOException - IO异常public static void out(Font font, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws IOException
font - 字体request - HttpServletRequestresponse - HttpServletResponseIOException - IO异常public static void out(int len,
Font font,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws IOException
len - 长度font - 字体request - HttpServletRequestresponse - HttpServletResponseIOException - IO异常public static void out(int width,
int height,
int len,
Font font,
javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws IOException
width - 宽度height - 高度len - 长度font - 字体request - HttpServletRequestresponse - HttpServletResponseIOException - IO异常public static void out(Captcha captcha, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws IOException
captcha - Captcharequest - HttpServletRequestresponse - HttpServletResponseIOException - IO异常public static boolean ver(String code, javax.servlet.http.HttpServletRequest request)
code - 用户输入的验证码request - HttpServletRequestpublic static void clear(javax.servlet.http.HttpServletRequest request)
request - HttpServletRequestpublic static void setHeader(javax.servlet.http.HttpServletResponse response)
response - HttpServletResponseCopyright © 2019. All rights reserved.