Loading TOC...

MarkLogic 10 Product Documentation
xdmp.uriIsFile

xdmp.uriIsFile(
   uri as String?
) as Boolean?

Summary

Returns true if a given URI refers to a file which exists on the current application server. Only returns true if the modules on the App Server is set to file system; always returns false if you are using a database for your modules. false Returns false if the file does not exist. Returns the empty sequence if the URI is the empty sequence.

Parameters
uri The URI to check. If the URI begins with a "/", it is relative to the root directory of the application server. Otherwise, it is relative to the current request URI.

Example

xdmp.uriIsFile("/sub-directory/test.xml");
=> true if test.xml exists in "sub-directory" relative
   to the root directory of the application server.

Stack Overflow iconStack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.