Changeset 725 for MDRepository
- Timestamp:
- 09/28/10 10:45:51 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
MDRepository/trunk/xquery/cmd-model.xqm
r714 r725 277 277 (: let $key := xdb:decode(($doc-name, $id)[1]) 278 278 return ft:query(//MdSelfLink, <term>{$key}</term>)[matches(., concat("^", $key, "$"))]/ancestor::CMD :) 279 else if (empty($doc-name) ) then280 collection($ id)//IsPartOf[. = "root"]/ancestor::CMD279 else if (empty($doc-name) or $id=$cmd-model:collectionRoot ) then 280 collection($cmd-model:cmdiMirrorPath)//IsPartOf[. = $cmd-model:collectionRoot]/ancestor::CMD 281 281 else 282 282 doc(concat($id, "/", $doc-name)) … … 307 307 :) 308 308 declare function cmd-model:get-collections($collections as xs:string+, $format as xs:string, $max-depth as xs:integer) as item() { 309 let $names := ($cmd-model:commonFreqsPath, cmd-model:make-compound-doc-name($collections, "collection", $max-depth)),309 let $names := ($cmd-model:commonFreqsPath, cmd-model:make-compound-doc-name($collections, "collection", xs:string($max-depth))), 310 310 $dummy := 311 311 if (cmd-model:is-doc-available($names[1], $names[2])) then
Note: See TracChangeset
for help on using the changeset viewer.