public function setLanguage($language)
    {
        $this->language = $language;

        foreach ($this->countries as $country) {
            $this->countriesTranslated[$country->getIsoAlpha2()] = $country->getTranslation($this->language)['common'];
        }

        return $this;
    }
public function setLanguage($language)
    {
        $this->language = $language;

        foreach ($this->countries as $country) {
            $this->countriesTranslated[$country->getIsoAlpha2()] = $country->getTranslation($this->language)['common'];
        }

        return $this;
    }
public function setLanguage ( $ language ) { $ this -> language = $ language ; foreach ( $ this -> countries as $ country ) { $ this -> countriesTranslated [ $ country -> getIsoAlpha2 ( ) ] = $ country -> getTranslation ( $ this -> language ) [ 'common' ] ; } return $ this ; }
Change the default translation language using the three character ISO 639-3 code of the desired language.
Country name translations will be reloaded.

@param string $language
@return $this
Change the default translation language using the three character ISO 639 - 3 code of the desired language . Country name translations will be reloaded .