public function getLocale() { // sanity check if (!$this->hasLocale()) { throw new LocaleNotSetException("The locale needs to be set before calling L4gettext::getLocale()"); } // return locale return $this->locale; }