X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;ds=sidebyside;f=inc%2Fclasses%2Fmain%2Fhelper%2Fcaptcha%2Fclass_BaseCaptcha.php;h=c6bf892b88b6260427037937e8c321d878884903;hb=607a11e2c22949ea0647568c17d62a605595e83b;hp=9cef2076fb7cebc05b757fe2597198c94a4403f7;hpb=0cd57c3885f00ad77fc599e53ed2f2d5e7ac267f;p=core.git diff --git a/inc/classes/main/helper/captcha/class_BaseCaptcha.php b/inc/classes/main/helper/captcha/class_BaseCaptcha.php index 9cef2076..c6bf892b 100644 --- a/inc/classes/main/helper/captcha/class_BaseCaptcha.php +++ b/inc/classes/main/helper/captcha/class_BaseCaptcha.php @@ -4,7 +4,7 @@ * * @author Roland Haeder * @version 0.0.0 - * @copyright Copyright (c) 2007, 2008 Roland Haeder, 2009 Core Developer Team + * @copyright Copyright (c) 2007, 2008 Roland Haeder, 2009 - 2012 Core Developer Team * @license GNU GPL 3.0 or any newer version * @link http://www.ship-simu.org * @@ -22,16 +22,6 @@ * along with this program. If not, see . */ class BaseCaptcha extends BaseHelper { - /** - * A helper instance for the form - */ - private $helperInstance = null; - - /** - * Instance of an RNG - */ - private $rngInstance = null; - /** * Protected constructor * @@ -49,37 +39,9 @@ class BaseCaptcha extends BaseHelper { * @param $extraInstance An extra instance, just for better hash data * @return void */ - protected final function initializeRandomNumberGenerator (FrameworkInterface $extraInstance = null) { + protected final function initializeRandomNumberGenerator (FrameworkInterface $extraInstance = NULL) { // Get an RNG from factory - $this->rngInstance = ObjectFactory::createObjectByConfiguredName('rng_class', array($extraInstance)); - } - - /** - * Getter for RNG instance - * - * @return $rngInstance An instance of a random number generator (RNG) - */ - public final function getRngInstance () { - return $this->rngInstance; - } - - /** - * Setter for helper instance - * - * @param $helperInstance An instance of a helper class - * @return void - */ - protected final function setHelperInstance (HelpableTemplate $helperInstance) { - $this->helperInstance = $helperInstance; - } - - /** - * Getter for helper instance - * - * @return $helperInstance An instance of a helper class - */ - public final function getHelperInstance () { - return $this->helperInstance; + $this->setRngInstance(ObjectFactory::createObjectByConfiguredName('rng_class', array($extraInstance))); } }