org.opencms.frontend.templateone.form
Class CmsCaptchaService

java.lang.Object
  extended by AbstractManageableImageCaptchaService
      extended by org.opencms.frontend.templateone.form.CmsCaptchaService

public class CmsCaptchaService
extends AbstractManageableImageCaptchaService

Provides the facility to create and cache the captcha images.


Constructor Summary
CmsCaptchaService(CmsCaptchaSettings captchaSettings)
          Creates a new captcha service.
 
Method Summary
protected  void setSettings(CmsCaptchaSettings settings)
          Implant new captcha settings to this service.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CmsCaptchaService

public CmsCaptchaService(CmsCaptchaSettings captchaSettings)
Creates a new captcha service.

minGuarantedStorageDelayInSeconds = 180s maxCaptchaStoreSize = 100000 captchaStoreLoadBeforeGarbageCollection=75000

Parameters:
captchaSettings - the settings to render captcha images
Method Detail

setSettings

protected void setSettings(CmsCaptchaSettings settings)
Implant new captcha settings to this service.

This is an expensive method as new Image filters and many processing objects are allocated anew. Prefer using the CmsCaptchaServiceCache.getCaptchaService(CmsCaptchaSettings, org.opencms.file.CmsObject) method instead. It will return cached instances for equal settings.

Parameters:
settings - the captcha settings to implant.