| Constructor and Description |
|---|
Builder(int width,
int height)
Creates a
Captcha.Builder with specified width and height. |
| Modifier and Type | Method and Description |
|---|---|
Captcha.Builder |
addBackground()
Add a background using the default
TransparentBackground. |
Captcha.Builder |
addBackground(Background background)
Add a background using the given
Background. |
Captcha.Builder |
addBorder()
Draw a single-pixel wide black border around the image.
|
Captcha.Builder |
addNoise()
Add noise using the default
CurvedLineNoiseProducer. |
Captcha.Builder |
addNoise(NoiseProducer noise)
Add noise using the given
NoiseProducer. |
Captcha.Builder |
addText()
Add answer to the captcha using the
DefaultTextProducer. |
Captcha.Builder |
addText(TextProducer txtProd)
ADd answer to the captcha using the given
TextProducer. |
Captcha.Builder |
addText(TextProducer txtProd,
WordRenderer wRenderer)
ADd answer to the captcha using the given
TextProducer, and render it to the image using the given
WordRenderer. |
Captcha.Builder |
addText(WordRenderer wordRenderer)
Add answer to the captcha with specified instance of
WordRenderer. |
Captcha |
build()
Builds the captcha.
|
Captcha.Builder |
gimp()
Gimp the image using the default
FishEyeRenderer. |
Captcha.Builder |
gimp(Renderer renderer)
Gimp the image using the given
Renderer. |
public Builder(int width,
int height)
Captcha.Builder with specified width and height.width - width of captcha.height - height of captcha.public Captcha.Builder addBackground()
TransparentBackground.Captcha.Builder.public Captcha.Builder addBackground(Background background)
Background.background - the instance of Background.Captcha.Builder.public Captcha.Builder addText(WordRenderer wordRenderer)
WordRenderer.wordRenderer - the instance of WordRenderer.Captcha.Builder.public Captcha.Builder addText()
DefaultTextProducer.Captcha.Builder.public Captcha.Builder addText(TextProducer txtProd)
TextProducer.txtProd - the instance of TextProducer.Captcha.Builder.public Captcha.Builder addText(TextProducer txtProd, WordRenderer wRenderer)
TextProducer, and render it to the image using the given
WordRenderer.txtProd - the instance of TextProducer.wRenderer - the instance of WordRenderer.Captcha.Builder.public Captcha.Builder addNoise()
CurvedLineNoiseProducer.Captcha.Builder.public Captcha.Builder addNoise(NoiseProducer noise)
NoiseProducer.noise - the instance of NoiseProducer.Captcha.Builder.public Captcha.Builder gimp()
FishEyeRenderer.Captcha.Builder.public Captcha.Builder gimp(Renderer renderer)
Renderer.renderer - the instance of Renderer.Captcha.Builder.public Captcha.Builder addBorder()
Captcha.Builder.public Captcha build()
Copyright © 2015. All rights reserved.