public static class Captcha.Builder extends Object implements Serializable
| 构造器和说明 |
|---|
Captcha.Builder(int width,
int height) |
| 限定符和类型 | 方法和说明 |
|---|---|
Captcha.Builder |
addBackground()
Add a background using the default
BackgroundProducer (a TransparentBackgroundProducer). |
Captcha.Builder |
addBackground(BackgroundProducer bgProd)
Add a background using the given
BackgroundProducer. |
Captcha.Builder |
addBorder()
Draw a single-pixel wide black border around the image.
|
Captcha.Builder |
addNoise()
Add noise using the default
NoiseProducer (a CurvedLineNoiseProducer). |
Captcha.Builder |
addNoise(NoiseProducer nProd)
Add noise using the given NoiseProducer.
|
Captcha.Builder |
addText()
Generate the answer to the CAPTCHA using the
DefaultTextProducer. |
Captcha.Builder |
addText(TextProducer txtProd)
Generate the answer to the CAPTCHA using the given
TextProducer. |
Captcha.Builder |
addText(TextProducer txtProd,
WordRenderer wRenderer)
Generate the answer to the CAPTCHA using the given
TextProducer, and render it to the image using the given
WordRenderer. |
Captcha.Builder |
addText(WordRenderer wRenderer)
Generate the answer to the CAPTCHA using the default
TextProducer, and render it to the image using the given
WordRenderer. |
Captcha |
build()
Build the CAPTCHA.
|
Captcha.Builder |
gimp()
Gimp the image using the default
GimpyRenderer (a RippleGimpyRenderer). |
Captcha.Builder |
gimp(GimpyRenderer gimpy)
Gimp the image using the given
GimpyRenderer. |
String |
toString() |
public Captcha.Builder addBackground()
BackgroundProducer (a TransparentBackgroundProducer).public Captcha.Builder addBackground(BackgroundProducer bgProd)
BackgroundProducer.bgProd - public Captcha.Builder addText()
DefaultTextProducer.public Captcha.Builder addText(TextProducer txtProd)
TextProducer.txtProd - public Captcha.Builder addText(WordRenderer wRenderer)
TextProducer, and render it to the image using the given
WordRenderer.wRenderer - public Captcha.Builder addText(TextProducer txtProd, WordRenderer wRenderer)
TextProducer, and render it to the image using the given
WordRenderer.txtProd - wRenderer - public Captcha.Builder addNoise()
NoiseProducer (a CurvedLineNoiseProducer).public Captcha.Builder addNoise(NoiseProducer nProd)
nProd - public Captcha.Builder gimp()
GimpyRenderer (a RippleGimpyRenderer).public Captcha.Builder gimp(GimpyRenderer gimpy)
GimpyRenderer.gimpy - public Captcha.Builder addBorder()
public Captcha build()
Copyright © 2015. All rights reserved.