@@ 866-877 (lines=12) @@ | ||
863 | * |
|
864 | * @return void |
|
865 | */ |
|
866 | public function setRegion($value) |
|
867 | { |
|
868 | if (!is_string($value)) { |
|
869 | throw new MapperArgumentException('Invalid map region.'); |
|
870 | } |
|
871 | ||
872 | if (!in_array($value, $this->regions)) { |
|
873 | throw new MapperArgumentException('Region is required in ISO 3166-1 code format.'); |
|
874 | } |
|
875 | ||
876 | $this->region = $value; |
|
877 | } |
|
878 | ||
879 | /** |
|
880 | * Get the Google Maps region. |
|
@@ 898-909 (lines=12) @@ | ||
895 | * |
|
896 | * @return void |
|
897 | */ |
|
898 | public function setLanguage($value) |
|
899 | { |
|
900 | if (!is_string($value)) { |
|
901 | throw new MapperArgumentException('Invalid map language.'); |
|
902 | } |
|
903 | ||
904 | if (!in_array($value, $this->languages)) { |
|
905 | throw new MapperArgumentException('Language is required in ISO 639-1 code format.'); |
|
906 | } |
|
907 | ||
908 | $this->language = $value; |
|
909 | } |
|
910 | ||
911 | /** |
|
912 | * Get the Google Maps language. |