public function setLocale($locale)
    {
        $result = true;

        // Check if locale is valid
        if (!$this->isValidLocale($locale)) {
            throw new Doozr_I18n_Service_Exception(
                sprintf('The locale "%s" is not valid.', $locale)
            );
        }

        $this->locale = $locale;

        return $result;
    }
public function setLocale($locale)
    {
        $result = true;

        // Check if locale is valid
        if (!$this->isValidLocale($locale)) {
            throw new Doozr_I18n_Service_Exception(
                sprintf('The locale "%s" is not valid.', $locale)
            );
        }

        $this->locale = $locale;

        return $result;
    }
public function setLocale ( $ locale ) { $ result = true ; // Check if locale is valid if ( ! $ this -> isValidLocale ( $ locale ) ) { throw new Doozr_I18n_Service_Exception ( sprintf ( 'The locale "%s" is not valid.' , $ locale ) ) ; } $ this -> locale = $ locale ; return $ result ; }
Setter for locale.

@param string $locale The locale to set as active

@author Benjamin Carl <opensource@clickalicious.de>

@return bool TRUE on success, otherwise FALSE

@throws Doozr_I18n_Service_Exception
Setter for locale .