public function translate($string, array $arguments = null, $htmlEscape = true)
    {
        if (null === $this->getI18n()) {
            throw new Doozr_Form_Service_Exception(
                'Please set an instance of Doozr_I18n_Service (or compatible) first before calling encrypt()'
            );
        }

        return $this->getI18n()->translate($string, $htmlEscape, $arguments);
    }
public function translate($string, array $arguments = null, $htmlEscape = true)
    {
        if (null === $this->getI18n()) {
            throw new Doozr_Form_Service_Exception(
                'Please set an instance of Doozr_I18n_Service (or compatible) first before calling encrypt()'
            );
        }

        return $this->getI18n()->translate($string, $htmlEscape, $arguments);
    }
public function translate ( $ string , array $ arguments = null , $ htmlEscape = true ) { if ( null === $ this -> getI18n ( ) ) { throw new Doozr_Form_Service_Exception ( 'Please set an instance of Doozr_I18n_Service (or compatible) first before calling encrypt()' ) ; } return $ this -> getI18n ( ) -> translate ( $ string , $ htmlEscape , $ arguments ) ; }
Translates the passed value to the current locale via I18n service.

@param string $string     String to be translated
@param array  $arguments  Arguments to pass to translator (e.g. for values in translations).
@param bool   $htmlEscape TRUE to HTML-escape translated string. Never HTML-escape interpolated variables.

@author Benjamin Carl <opensource@clickalicious.de>

@return string Result of translation, input string as fallback

@throws Doozr_Form_Service_Exception
Translates the passed value to the current locale via I18n service .