@@ -20,7 +20,7 @@ |
||
| 20 | 20 | |
| 21 | 21 | public function numberSymbols() { |
| 22 | 22 | return array( |
| 23 | - self::NEGATIVE => self::LTR_MARK . self::HYPHEN, |
|
| 23 | + self::NEGATIVE => self::LTR_MARK.self::HYPHEN, |
|
| 24 | 24 | ); |
| 25 | 25 | } |
| 26 | 26 | } |
@@ -43,17 +43,17 @@ discard block |
||
| 43 | 43 | * @return string |
| 44 | 44 | */ |
| 45 | 45 | public function code() { |
| 46 | - $code = $this->language()->code() . '_' . $this->territory()->code(); |
|
| 46 | + $code = $this->language()->code().'_'.$this->territory()->code(); |
|
| 47 | 47 | |
| 48 | 48 | if ($this->script() != $this->language()->defaultScript()) { |
| 49 | - $code .= '@' . strtolower($this->script()->unicodeName()); |
|
| 49 | + $code .= '@'.strtolower($this->script()->unicodeName()); |
|
| 50 | 50 | } |
| 51 | 51 | |
| 52 | 52 | if ($this->variant()) { |
| 53 | 53 | if ($this->variant()->code() === 'posix') { |
| 54 | 54 | $code = 'POSIX'; |
| 55 | 55 | } else { |
| 56 | - $code .= '@' . $this->variant()->code(); |
|
| 56 | + $code .= '@'.$this->variant()->code(); |
|
| 57 | 57 | } |
| 58 | 58 | } |
| 59 | 59 | |
@@ -131,9 +131,9 @@ discard block |
||
| 131 | 131 | */ |
| 132 | 132 | public function htmlAttributes() { |
| 133 | 133 | if ($this->direction() === 'rtl' || $this->direction() !== $this->script()->direction()) { |
| 134 | - return 'lang="' . $this->languageTag() . '" dir="' . $this->direction() . '"'; |
|
| 134 | + return 'lang="'.$this->languageTag().'" dir="'.$this->direction().'"'; |
|
| 135 | 135 | } else { |
| 136 | - return 'lang="' . $this->languageTag() . '"'; |
|
| 136 | + return 'lang="'.$this->languageTag().'"'; |
|
| 137 | 137 | } |
| 138 | 138 | } |
| 139 | 139 | |
@@ -146,13 +146,13 @@ discard block |
||
| 146 | 146 | public function languageTag() { |
| 147 | 147 | $language_tag = $this->language()->code(); |
| 148 | 148 | if ($this->script() != $this->language()->defaultScript()) { |
| 149 | - $language_tag .= '-' . $this->script()->code(); |
|
| 149 | + $language_tag .= '-'.$this->script()->code(); |
|
| 150 | 150 | } |
| 151 | 151 | if ($this->territory() != $this->language()->defaultTerritory()) { |
| 152 | - $language_tag .= '-' . $this->territory()->code(); |
|
| 152 | + $language_tag .= '-'.$this->territory()->code(); |
|
| 153 | 153 | } |
| 154 | 154 | if ($this->variant()) { |
| 155 | - $language_tag .= '-' . $this->variant()->code(); |
|
| 155 | + $language_tag .= '-'.$this->variant()->code(); |
|
| 156 | 156 | } |
| 157 | 157 | |
| 158 | 158 | return $language_tag; |
@@ -185,20 +185,20 @@ discard block |
||
| 185 | 185 | $integers = $parts[0]; |
| 186 | 186 | if (strlen($integers) >= $this->digitsFirstGroup() + $this->minimumGroupingDigits()) { |
| 187 | 187 | $todo = substr($integers, 0, -$this->digitsFirstGroup()); |
| 188 | - $integers = self::GROUP . substr($integers, -$this->digitsFirstGroup()); |
|
| 188 | + $integers = self::GROUP.substr($integers, -$this->digitsFirstGroup()); |
|
| 189 | 189 | while (strlen($todo) >= $this->digitsGroup() + $this->minimumGroupingDigits()) { |
| 190 | - $integers = self::GROUP . substr($todo, -$this->digitsGroup()) . $integers; |
|
| 190 | + $integers = self::GROUP.substr($todo, -$this->digitsGroup()).$integers; |
|
| 191 | 191 | $todo = substr($todo, 0, -$this->digitsGroup()); |
| 192 | 192 | } |
| 193 | - $integers = $todo . $integers; |
|
| 193 | + $integers = $todo.$integers; |
|
| 194 | 194 | } |
| 195 | 195 | if (count($parts) > 1) { |
| 196 | - $decimals = self::DECIMAL . $parts[1]; |
|
| 196 | + $decimals = self::DECIMAL.$parts[1]; |
|
| 197 | 197 | } else { |
| 198 | 198 | $decimals = ''; |
| 199 | 199 | } |
| 200 | 200 | |
| 201 | - return $this->digits($negative . $integers . $decimals); |
|
| 201 | + return $this->digits($negative.$integers.$decimals); |
|
| 202 | 202 | } |
| 203 | 203 | |
| 204 | 204 | /** |
@@ -19,7 +19,7 @@ |
||
| 19 | 19 | } |
| 20 | 20 | |
| 21 | 21 | protected function percentFormat() { |
| 22 | - return '%s' . self::PERCENT; |
|
| 22 | + return '%s'.self::PERCENT; |
|
| 23 | 23 | } |
| 24 | 24 | |
| 25 | 25 | public function territory() { |
@@ -30,7 +30,7 @@ |
||
| 30 | 30 | } |
| 31 | 31 | |
| 32 | 32 | protected function percentFormat() { |
| 33 | - return '%s' . self::PERCENT; |
|
| 33 | + return '%s'.self::PERCENT; |
|
| 34 | 34 | } |
| 35 | 35 | |
| 36 | 36 | } |
@@ -53,7 +53,7 @@ discard block |
||
| 53 | 53 | * @return string Translated text |
| 54 | 54 | */ |
| 55 | 55 | public function translateContext($context, $message) { |
| 56 | - $key = $context . chr(4) . $message; |
|
| 56 | + $key = $context.chr(4).$message; |
|
| 57 | 57 | if (isset($this->translations[$key])) { |
| 58 | 58 | return $this->translations[$key]; |
| 59 | 59 | } else { |
@@ -72,7 +72,7 @@ discard block |
||
| 72 | 72 | * @return string Translated text |
| 73 | 73 | */ |
| 74 | 74 | public function translatePlural($message1, $message2, $number) { |
| 75 | - $key = $message1 . chr(0) . $message2; |
|
| 75 | + $key = $message1.chr(0).$message2; |
|
| 76 | 76 | if (isset($this->translations[$key])) { |
| 77 | 77 | $plurals = explode(chr(0), $this->translations[$key]); |
| 78 | 78 | if (count($plurals) === $this->plural_rule->plurals()) { |
@@ -20,6 +20,6 @@ |
||
| 20 | 20 | } |
| 21 | 21 | |
| 22 | 22 | public function pluralRule() { |
| 23 | - throw new \DomainException('No plural rule defined for language ' . __CLASS__); |
|
| 23 | + throw new \DomainException('No plural rule defined for language '.__CLASS__); |
|
| 24 | 24 | } |
| 25 | 25 | } |
@@ -72,7 +72,7 @@ |
||
| 72 | 72 | private function readMoWords($fp, $offset, $count, $pack) { |
| 73 | 73 | fseek($fp, $offset); |
| 74 | 74 | |
| 75 | - return unpack($pack . $count, fread($fp, $count * 4)); |
|
| 75 | + return unpack($pack.$count, fread($fp, $count * 4)); |
|
| 76 | 76 | } |
| 77 | 77 | |
| 78 | 78 | /** |
@@ -47,8 +47,8 @@ |
||
| 47 | 47 | case 'php': |
| 48 | 48 | $translations = include $filename; |
| 49 | 49 | if (is_array($translations)) { |
| 50 | - $this->translations = $translations; |
|
| 51 | - } |
|
| 50 | + $this->translations = $translations; |
|
| 51 | + } |
|
| 52 | 52 | break; |
| 53 | 53 | } |
| 54 | 54 | } |
@@ -30,6 +30,6 @@ |
||
| 30 | 30 | } |
| 31 | 31 | |
| 32 | 32 | protected function percentFormat() { |
| 33 | - return '%s' . self::NBSP . self::PERCENT; |
|
| 33 | + return '%s'.self::NBSP.self::PERCENT; |
|
| 34 | 34 | } |
| 35 | 35 | } |
@@ -30,6 +30,6 @@ |
||
| 30 | 30 | } |
| 31 | 31 | |
| 32 | 32 | protected function percentFormat() { |
| 33 | - return '%s' . self::NBSP . self::PERCENT; |
|
| 33 | + return '%s'.self::NBSP.self::PERCENT; |
|
| 34 | 34 | } |
| 35 | 35 | } |