@@ -110,6 +110,9 @@ discard block |
||
| 110 | 110 | $this->initDelimiterAttributes($node); |
| 111 | 111 | } |
| 112 | 112 | |
| 113 | + /** |
|
| 114 | + * @param integer $citationNumber |
|
| 115 | + */ |
|
| 113 | 116 | public function render($data, $citationNumber = null) |
| 114 | 117 | { |
| 115 | 118 | $lastName = null; |
@@ -226,7 +229,7 @@ discard block |
||
| 226 | 229 | } |
| 227 | 230 | |
| 228 | 231 | /** |
| 229 | - * @param $name |
|
| 232 | + * @param \stdClass $name |
|
| 230 | 233 | * @return string |
| 231 | 234 | */ |
| 232 | 235 | private function getNamesString($name, $rank) |
@@ -344,7 +347,7 @@ discard block |
||
| 344 | 347 | } |
| 345 | 348 | |
| 346 | 349 | /** |
| 347 | - * @param $text |
|
| 350 | + * @param string $text |
|
| 348 | 351 | * @param $etAl |
| 349 | 352 | * @param $resultNames |
| 350 | 353 | * @return string |
@@ -121,10 +121,10 @@ discard block |
||
| 121 | 121 | |
| 122 | 122 | $count = 0; |
| 123 | 123 | |
| 124 | - $hasPreceding = CiteProc::getContext()->getCitationItems()->hasKey($citationNumber-1); |
|
| 124 | + $hasPreceding = CiteProc::getContext()->getCitationItems()->hasKey($citationNumber - 1); |
|
| 125 | 125 | if ($hasPreceding) { |
| 126 | 126 | /** @var \stdClass $preceding */ |
| 127 | - $preceding = CiteProc::getContext()->getCitationItems()->get($citationNumber-1); |
|
| 127 | + $preceding = CiteProc::getContext()->getCitationItems()->get($citationNumber - 1); |
|
| 128 | 128 | } |
| 129 | 129 | |
| 130 | 130 | $subsequentSubstitution = CiteProc::getContext()->getCitationItems()->getSubsequentAuthorSubstitute(); |
@@ -191,7 +191,7 @@ discard block |
||
| 191 | 191 | which allows for advanced sorting. */ |
| 192 | 192 | |
| 193 | 193 | if ($this->form == 'count') { |
| 194 | - return (int)count($resultNames); |
|
| 194 | + return (int) count($resultNames); |
|
| 195 | 195 | } |
| 196 | 196 | |
| 197 | 197 | return $text; |
@@ -216,7 +216,7 @@ discard block |
||
| 216 | 216 | if (count($this->nameParts) > 0) { |
| 217 | 217 | /** @var NamePart $namePart */ |
| 218 | 218 | foreach ($this->nameParts as $namePart) { |
| 219 | - $nameObj->{$namePart->getName()} = $namePart->render($name); |
|
| 219 | + $nameObj->{$namePart->getName()} = $namePart->render($name); |
|
| 220 | 220 | } |
| 221 | 221 | } |
| 222 | 222 | |
@@ -266,7 +266,7 @@ discard block |
||
| 266 | 266 | |
| 267 | 267 | //remove last comma when no suffix exist. |
| 268 | 268 | $text = trim($text); |
| 269 | - $text = substr($text, -1) === "," ? substr($text, 0, strlen($text)-1) : $text; |
|
| 269 | + $text = substr($text, -1) === "," ? substr($text, 0, strlen($text) - 1) : $text; |
|
| 270 | 270 | break; |
| 271 | 271 | default: |
| 272 | 272 | /* |