Class JHLabsCaptchaEngine

  • All Implemented Interfaces:
    java.io.Serializable, CaptchaEngine

    public class JHLabsCaptchaEngine
    extends java.lang.Object
    implements CaptchaEngine, java.io.Serializable
    A captcha engine implemented with JH Labs libraries.

    Available in ZK PE and ZK EE.

    See also JH Labs

    Since:
    3.0.0
    Author:
    henrichen
    See Also:
    Serialized Form
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected int drawText​(java.awt.Graphics2D g2D, Captcha captcha)  
      byte[] generateCaptcha​(java.lang.Object data)
      Per the given data, generate the distortion Captcha image into a byte array.
      protected java.awt.image.BufferedImage rotateChar​(java.lang.String substr, int width, int height, java.awt.Font font, java.awt.Color fontColor, java.awt.Color bgColor)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • JHLabsCaptchaEngine

        public JHLabsCaptchaEngine()
    • Method Detail

      • generateCaptcha

        public byte[] generateCaptcha​(java.lang.Object data)
        Description copied from interface: CaptchaEngine
        Per the given data, generate the distortion Captcha image into a byte array.
        Specified by:
        generateCaptcha in interface CaptchaEngine
      • drawText

        protected int drawText​(java.awt.Graphics2D g2D,
                               Captcha captcha)
      • rotateChar

        protected java.awt.image.BufferedImage rotateChar​(java.lang.String substr,
                                                          int width,
                                                          int height,
                                                          java.awt.Font font,
                                                          java.awt.Color fontColor,
                                                          java.awt.Color bgColor)