| @@ 212-226 (lines=15) @@ | ||
| 209 | * @return string array class URI or null |
|
| 210 | */ |
|
| 211 | ||
| 212 | public function getAdditionalSearchProperties() |
|
| 213 | { |
|
| 214 | $resources = $this->resource->allResources("skosmos:showPropertyInSearch"); |
|
| 215 | $ret = array(); |
|
| 216 | foreach ($resources as $res) { |
|
| 217 | $prop = $res->getURI(); |
|
| 218 | if (EasyRdf\RdfNamespace::shorten($prop) !== null) // shortening property labels if possible |
|
| 219 | { |
|
| 220 | $prop = EasyRdf\RdfNamespace::shorten($prop); |
|
| 221 | } |
|
| 222 | ||
| 223 | $ret[] = $prop; |
|
| 224 | } |
|
| 225 | return $ret; |
|
| 226 | } |
|
| 227 | ||
| 228 | /** |
|
| 229 | * Queries whether the property should be shown with all the label language variations. |
|
| @@ 375-389 (lines=15) @@ | ||
| 372 | * @return string array class URI or null |
|
| 373 | */ |
|
| 374 | ||
| 375 | public function getHierarchyProperty() |
|
| 376 | { |
|
| 377 | $resources = $this->resource->allResources("skosmos:hierarchyProperty"); |
|
| 378 | $ret = array(); |
|
| 379 | foreach ($resources as $res) { |
|
| 380 | $prop = $res->getURI(); |
|
| 381 | if (EasyRdf\RdfNamespace::shorten($prop) !== null) // prefixing if possible |
|
| 382 | { |
|
| 383 | $prop = EasyRdf\RdfNamespace::shorten($prop); |
|
| 384 | } |
|
| 385 | ||
| 386 | $ret[] = $prop; |
|
| 387 | } |
|
| 388 | return empty($ret) ? array('skos:broader') : $ret; |
|
| 389 | } |
|
| 390 | ||
| 391 | /** |
|
| 392 | * Returns a boolean value set in the vocabularies.ttl config. |
|