|
@@ 312-318 (lines=7) @@
|
| 309 |
|
* @param string $uri |
| 310 |
|
* @param string $lang language identifier. |
| 311 |
|
*/ |
| 312 |
|
public function getConceptHierarchy($uri, $lang) |
| 313 |
|
{ |
| 314 |
|
$lang = $lang ? $lang : $this->getEnvLang(); |
| 315 |
|
$fallback = count($this->config->getLanguageOrder($lang)) > 1 ? $this->config->getLanguageOrder($lang)[1] : $this->config->getDefaultLanguage(); |
| 316 |
|
$props = $this->config->getHierarchyProperty(); |
| 317 |
|
return $this->getSparql()->queryParentList($uri, $lang, $fallback, $props); |
| 318 |
|
} |
| 319 |
|
|
| 320 |
|
/** |
| 321 |
|
* Gets the child relations of a concept and whether these children have more children. |
|
@@ 324-330 (lines=7) @@
|
| 321 |
|
* Gets the child relations of a concept and whether these children have more children. |
| 322 |
|
* @param string $uri |
| 323 |
|
*/ |
| 324 |
|
public function getConceptChildren($uri, $lang) |
| 325 |
|
{ |
| 326 |
|
$lang = $lang ? $lang : $this->getEnvLang(); |
| 327 |
|
$fallback = count($this->config->getLanguageOrder($lang)) > 1 ? $this->config->getLanguageOrder($lang)[1] : $this->config->getDefaultLanguage(); |
| 328 |
|
$props = $this->config->getHierarchyProperty(); |
| 329 |
|
return $this->getSparql()->queryChildren($uri, $lang, $fallback, $props); |
| 330 |
|
} |
| 331 |
|
|
| 332 |
|
/** |
| 333 |
|
* Gets the skos:narrower relations of a concept. |