@@ -157,7 +157,7 @@ discard block |
||
157 | 157 | * Reads phone prefix data from the provides file path and invokes the given handler for each |
158 | 158 | * mapping read. |
159 | 159 | * |
160 | - * @param $filePath |
|
160 | + * @param string $filePath |
|
161 | 161 | * @param $handler |
162 | 162 | * @return array |
163 | 163 | * @throws \InvalidArgumentException |
@@ -204,6 +204,9 @@ discard block |
||
204 | 204 | return $this->getFilePath($language . DIRECTORY_SEPARATOR . $code . self::DATA_FILE_EXTENSION); |
205 | 205 | } |
206 | 206 | |
207 | + /** |
|
208 | + * @param string $fileName |
|
209 | + */ |
|
207 | 210 | private function getFilePath($fileName) |
208 | 211 | { |
209 | 212 | $path = $this->inputDir . $fileName; |
@@ -279,6 +282,9 @@ discard block |
||
279 | 282 | $this->compressAccordingToEnglishData($this->englishMaps[$countryCode], $mappings); |
280 | 283 | } |
281 | 284 | |
285 | + /** |
|
286 | + * @param string $textFile |
|
287 | + */ |
|
282 | 288 | private function getEnglishDataPath($textFile) |
283 | 289 | { |
284 | 290 | return "en" . DIRECTORY_SEPARATOR . substr($textFile, 3, 2) . self::DATA_FILE_EXTENSION; |
@@ -25,6 +25,9 @@ discard block |
||
25 | 25 | */ |
26 | 26 | private $prefixFileReader = null; |
27 | 27 | |
28 | + /** |
|
29 | + * @param string $phonePrefixDataDirectory |
|
30 | + */ |
|
28 | 31 | private function __construct($phonePrefixDataDirectory) |
29 | 32 | { |
30 | 33 | if(!extension_loaded('intl')) { |
@@ -104,7 +107,7 @@ discard block |
||
104 | 107 | * number is from. If it could be from many territories, nothing is returned. |
105 | 108 | * |
106 | 109 | * @param PhoneNumber $number |
107 | - * @param $locale |
|
110 | + * @param string $locale |
|
108 | 111 | * @return string |
109 | 112 | */ |
110 | 113 | private function getCountryNameForNumber(PhoneNumber $number, $locale) |
@@ -847,7 +847,7 @@ discard block |
||
847 | 847 | * This version exists since calculating the phone number type is expensive; if we have already |
848 | 848 | * done this, we don't want to do it again. |
849 | 849 | * |
850 | - * @param PhoneNumber|PhoneNumberType $phoneNumberObjOrType A PhoneNumber object, or a PhoneNumberType integer |
|
850 | + * @param integer $phoneNumberObjOrType A PhoneNumber object, or a PhoneNumberType integer |
|
851 | 851 | * @param int|null $countryCallingCode Used when passing a PhoneNumberType |
852 | 852 | * @return bool |
853 | 853 | */ |
@@ -1801,7 +1801,7 @@ discard block |
||
1801 | 1801 | * Normalizes a string of characters representing a phone number. This converts wide-ascii and |
1802 | 1802 | * arabic-indic numerals to European numerals, and strips punctuation and alpha characters. |
1803 | 1803 | * |
1804 | - * @param $number string a string of characters representing a phone number |
|
1804 | + * @param string $number string a string of characters representing a phone number |
|
1805 | 1805 | * @return string the normalized string version of the phone number |
1806 | 1806 | */ |
1807 | 1807 | public static function normalizeDigitsOnly($number) |
@@ -2747,7 +2747,7 @@ discard block |
||
2747 | 2747 | * |
2748 | 2748 | * @param PhoneNumber $number the phone number to be formatted |
2749 | 2749 | * @param int $numberFormat the format the phone number should be formatted into |
2750 | - * @param array $userDefinedFormats formatting rules specified by clients |
|
2750 | + * @param NumberFormat[] $userDefinedFormats formatting rules specified by clients |
|
2751 | 2751 | * @return String the formatted phone number |
2752 | 2752 | */ |
2753 | 2753 | public function formatByPattern(PhoneNumber $number, $numberFormat, array $userDefinedFormats) |
@@ -3140,6 +3140,10 @@ discard block |
||
3140 | 3140 | $this->stringEndsWithString($secondNumberNationalNumber, $firstNumberNationalNumber); |
3141 | 3141 | } |
3142 | 3142 | |
3143 | + /** |
|
3144 | + * @param string $hayStack |
|
3145 | + * @param string $needle |
|
3146 | + */ |
|
3143 | 3147 | protected function stringEndsWithString($hayStack, $needle) |
3144 | 3148 | { |
3145 | 3149 | $revNeedle = strrev($needle); |
@@ -61,7 +61,7 @@ discard block |
||
61 | 61 | |
62 | 62 | /** |
63 | 63 | * @internal |
64 | - * @param $regex |
|
64 | + * @param string $regex |
|
65 | 65 | * @param bool $removeWhitespace |
66 | 66 | * @return string |
67 | 67 | */ |
@@ -289,7 +289,7 @@ discard block |
||
289 | 289 | * @internal |
290 | 290 | * @param \DOMElement $element |
291 | 291 | * @param string $nationalPrefix |
292 | - * @return mixed|string |
|
292 | + * @return string |
|
293 | 293 | */ |
294 | 294 | public static function getDomesticCarrierCodeFormattingRuleFromElement(\DOMElement $element, $nationalPrefix) |
295 | 295 | { |
@@ -769,7 +769,7 @@ discard block |
||
769 | 769 | } |
770 | 770 | |
771 | 771 | /** |
772 | - * @param $metadataCollection PhoneMetadata[] |
|
772 | + * @param PhoneMetadata[] $metadataCollection PhoneMetadata[] |
|
773 | 773 | * @return array |
774 | 774 | */ |
775 | 775 | public static function buildCountryCodeToRegionCodeMap($metadataCollection) |