public function setLocale($locale) { if (is_string($locale)) { $this->locale = $locale; } return $this; }