| @@ -3,6 +3,9 @@ | ||
| 3 | 3 | class LabelSkosXL extends DataObject | 
| 4 | 4 |  { | 
| 5 | 5 | |
| 6 | + /** | |
| 7 | + * @param Model $model | |
| 8 | + */ | |
| 6 | 9 | public function __construct($model, $resource) | 
| 7 | 10 |      { | 
| 8 | 11 | parent::__construct($model, $resource); | 
| @@ -124,8 +124,8 @@ | ||
| 124 | 124 | */ | 
| 125 | 125 | public function getEnvLang() | 
| 126 | 126 |      { | 
| 127 | - // get language from locale, same as used by gettext, set by Controller | |
| 128 | -       return substr(getenv("LC_ALL"), 0, 2); // @codeCoverageIgnore | |
| 127 | + // get language from locale, same as used by gettext, set by Controller | |
| 128 | +        return substr(getenv("LC_ALL"), 0, 2); // @codeCoverageIgnore | |
| 129 | 129 | } | 
| 130 | 130 | |
| 131 | 131 | /** | 
| @@ -7,11 +7,11 @@ | ||
| 7 | 7 | abstract class BaseConfig extends DataObject | 
| 8 | 8 |  { | 
| 9 | 9 | |
| 10 | - /** | |
| 11 | - * Returns a boolean value based on a literal value from the config.ttl configuration. | |
| 12 | - * @param string $property the property to query | |
| 13 | - * @param boolean $default the default value if the value is not set in configuration | |
| 14 | - */ | |
| 10 | + /** | |
| 11 | + * Returns a boolean value based on a literal value from the config.ttl configuration. | |
| 12 | + * @param string $property the property to query | |
| 13 | + * @param boolean $default the default value if the value is not set in configuration | |
| 14 | + */ | |
| 15 | 15 | protected function getBoolean($property, $default = false) | 
| 16 | 16 |      { | 
| 17 | 17 | $val = $this->getResource()->getLiteral($property); | 
| @@ -517,13 +517,13 @@ | ||
| 517 | 517 | |
| 518 | 518 | $defaultPropLabel = $this->model->getDefaultSparql()->queryLabel($longUri, ''); | 
| 519 | 519 | |
| 520 | -					if($envLangLabels) { | |
| 521 | - $proplabel = $envLangLabels[$this->getEnvLang()]; | |
| 520 | +          if($envLangLabels) { | |
| 521 | + $proplabel = $envLangLabels[$this->getEnvLang()]; | |
| 522 | 522 |                      } else { | 
| 523 | -						if($defaultPropLabel) { | |
| 524 | - $proplabel = $defaultPropLabel['']; | |
| 525 | - } | |
| 526 | - } | |
| 523 | +            if($defaultPropLabel) { | |
| 524 | + $proplabel = $defaultPropLabel['']; | |
| 525 | + } | |
| 526 | + } | |
| 527 | 527 | } | 
| 528 | 528 | |
| 529 | 529 | // look for superproperties in the current graph | 
| @@ -74,6 +74,7 @@ discard block | ||
| 74 | 74 | * @param Vocabulary $vocab | 
| 75 | 75 | * @param EasyRdf\Resource $resource | 
| 76 | 76 | * @param EasyRdf\Graph $graph | 
| 77 | + * @param string|null $clang | |
| 77 | 78 | */ | 
| 78 | 79 | public function __construct($model, $vocab, $resource, $graph, $clang) | 
| 79 | 80 |      { | 
| @@ -738,6 +739,7 @@ discard block | ||
| 738 | 739 | |
| 739 | 740 | /** | 
| 740 | 741 | * Gets the groups/arrays the concept belongs to. | 
| 742 | + * @param boolean $includeArrays | |
| 741 | 743 | */ | 
| 742 | 744 |      private function getCollections($includeArrays) { | 
| 743 | 745 | $groups = array(); | 
| @@ -30,14 +30,14 @@ | ||
| 30 | 30 | $url = $baseurl . "$vocid/"; | 
| 31 | 31 |          } else { | 
| 32 | 32 | |
| 33 | -   	        if ($localname !== $uri && $localname === urlencode($localname)) { | |
| 34 | - // the URI can be shortened | |
| 33 | +              if ($localname !== $uri && $localname === urlencode($localname)) { | |
| 34 | + // the URI can be shortened | |
| 35 | 35 | $url = $baseurl . "$vocid/page/$localname"; | 
| 36 | 36 |              } else { | 
| 37 | 37 | // must use full URI | 
| 38 | -   	            $query = http_build_query(array('uri'=>$uri)); | |
| 38 | +                  $query = http_build_query(array('uri'=>$uri)); | |
| 39 | 39 | $url = $baseurl . "$vocid/page/?" . $query; | 
| 40 | - } | |
| 40 | + } | |
| 41 | 41 | } | 
| 42 | 42 | $this->redirect303($url); | 
| 43 | 43 | } | 
| @@ -169,6 +169,8 @@ | ||
| 169 | 169 | |
| 170 | 170 | /** | 
| 171 | 171 | * Return the mapping as a JSKOS-compatible array. | 
| 172 | + * @param string $lang | |
| 173 | + * @param string $hrefLink | |
| 172 | 174 | * @return array | 
| 173 | 175 | */ | 
| 174 | 176 | public function asJskos($queryExVocabs = true, $lang = null, $hrefLink = null) | 
| @@ -266,6 +266,7 @@ discard block | ||
| 266 | 266 | |
| 267 | 267 | /** | 
| 268 | 268 | * Returns skosmos:marcSourcecode value set in config.ttl. | 
| 269 | + * @param string $lang | |
| 269 | 270 | * @return string marcsource name | 
| 270 | 271 | */ | 
| 271 | 272 | public function getMarcSourceCode($lang = null) | 
| @@ -275,7 +276,7 @@ discard block | ||
| 275 | 276 | |
| 276 | 277 | /** | 
| 277 | 278 | * Returns a boolean value set in the config.ttl config. | 
| 278 | - * @return array array of concept class URIs (can be empty) | |
| 279 | + * @return string[] array of concept class URIs (can be empty) | |
| 279 | 280 | */ | 
| 280 | 281 | public function getIndexClasses() | 
| 281 | 282 |      { | 
| @@ -284,7 +285,7 @@ discard block | ||
| 284 | 285 | |
| 285 | 286 | /** | 
| 286 | 287 | * Returns skosmos:externalProperty values set in the config.ttl config. | 
| 287 | - * @return array array of external property URIs (can be empty) | |
| 288 | + * @return string[] array of external property URIs (can be empty) | |
| 288 | 289 | */ | 
| 289 | 290 | public function getExtProperties() | 
| 290 | 291 |      { | 
| @@ -410,6 +411,7 @@ discard block | ||
| 410 | 411 | |
| 411 | 412 | /** | 
| 412 | 413 | * Returns the vocabulary dc:type value(s) with their labels and uris, if set in the vocabulary configuration. | 
| 414 | + * @param string $lang | |
| 413 | 415 | * @return array of objects or an empty array | 
| 414 | 416 | */ | 
| 415 | 417 | public function getTypes($lang = null) | 
| @@ -23,6 +23,7 @@ discard block | ||
| 23 | 23 | |
| 24 | 24 | /** | 
| 25 | 25 | * Initializes the Model object. | 
| 26 | + * @param Model $model | |
| 26 | 27 | */ | 
| 27 | 28 | public function __construct($model) | 
| 28 | 29 |      { | 
| @@ -290,7 +291,7 @@ discard block | ||
| 290 | 291 | * Sends HTTP headers. Simply calls PHP built-in header function. But being | 
| 291 | 292 | * a function here, it can easily be tested/mocked. | 
| 292 | 293 | * | 
| 293 | - * @param $header string header to be sent | |
| 294 | + * @param string $header string header to be sent | |
| 294 | 295 | */ | 
| 295 | 296 | protected function sendHeader($header) | 
| 296 | 297 |      { | 
| @@ -33,16 +33,16 @@ | ||
| 33 | 33 | // Encrypt the current time | 
| 34 | 34 | $honey_time_encrypted = $this->getEncryptedTime(); | 
| 35 | 35 | return '<div id="' . $honey_name . '_wrap" style="display:none;">' . "\r\n" . | 
| 36 | - '<input name="' . $honey_name . '" type="text" value="" id="' . $honey_name . '"/>' . "\r\n" . | |
| 37 | - '<input name="' . $honey_time . '" type="text" value="' . $honey_time_encrypted . '"/>' . "\r\n" . | |
| 36 | + '<input name="' . $honey_name . '" type="text" value="" id="' . $honey_name . '"/>' . "\r\n" . | |
| 37 | + '<input name="' . $honey_time . '" type="text" value="' . $honey_time_encrypted . '"/>' . "\r\n" . | |
| 38 | 38 | '</div>'; | 
| 39 | 39 | } | 
| 40 | 40 | /** | 
| 41 | - * Validate honeypot is empty | |
| 42 | - * | |
| 43 | - * @param mixed $value | |
| 44 | - * @return boolean | |
| 45 | - */ | |
| 41 | + * Validate honeypot is empty | |
| 42 | + * | |
| 43 | + * @param mixed $value | |
| 44 | + * @return boolean | |
| 45 | + */ | |
| 46 | 46 | public function validateHoneypot($value) | 
| 47 | 47 |      { | 
| 48 | 48 |          if ($this->disabled) { |