⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 captchaproducer.java

📁 基于Java平台的、功能强大的验证码图片生成工具
💻 JAVA
字号:
/*
 * Created on Sep 15, 2005
 *
 * To change the template for this generated file go to
 * Window>Preferences>Java>Code Generation>Code and Comments
 */
package nl.captcha.servlet;

import java.io.IOException;
import java.io.OutputStream;
import java.util.Properties;

import nl.captcha.obscurity.BackgroundProducer;
import nl.captcha.obscurity.GimpyEngine;
import nl.captcha.text.TextProducer;
import nl.captcha.text.WordRenederer;

/**
 * @author Administrator
 *
 * Classes implementing this interface will be responsible for
 * creating the base
 */
public interface CaptchaProducer {
	/**
	 * Create an image which have witten a distorted text, text given 
	 * as parameter. The result image is put on the output stream
	 * 
	 * @param stream the OutputStrea where the image is written
	 * @param text the distorted characters written on imagage
	 * @throws IOException if an error occurs during the image written on
	 * output stream.
	 */
	public abstract void createImage(OutputStream stream, String text)
		throws IOException;
	/* (non-Javadoc)
	 * @see nl.captcha.servlet.CaptchaProducer#setBackGroundImageProducer(nl.captcha.obscurity.BackgroundProducer)
	 */
	public abstract void setBackGroundImageProducer(BackgroundProducer background);
	/* (non-Javadoc)
	 * @see nl.captcha.servlet.CaptchaProducer#setObscurificator()
	 */
	public abstract void setObscurificator(GimpyEngine engine);
	/**
	 * @param properties
	 */
	public abstract void setProperties(Properties properties);
	
	public abstract void setTextProducer(TextProducer textP);
	
	public abstract String createText();
	
	public abstract void  setWordRenderer(WordRenederer renederer);
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -