<?xml version="1.0" encoding="UTF-8"?><api:function-page xml:base="/apidoc/8.0/xdmp.directoryDelete.xml" generated="2015-10-07T16:36:00.016766-07:00" mode="javascript" xmlns:api="http://marklogic.com/rundmc/api"><api:function-name>xdmp.directoryDelete</api:function-name><api:suggest>xdmp.directorydelete</api:suggest><api:suggest>xdmp</api:suggest><api:suggest>directorydelete</api:suggest><api:function-link mode="xquery" fullname="xdmp:directory-delete">/apidoc/8.0/xdmp:directory-delete.xml</api:function-link><api:function mode="javascript" name="directoryDelete" type="builtin" lib="xdmp" category="UpdateBuiltins" hidden="false" bucket="MarkLogic Built-In Functions" prefix="xdmp" namespace="http://marklogic.com/xdmp" fullname="xdmp.directoryDelete"><api:summary>
  Deletes a directory and all of its child and descendant documents and
  directories from the database.
</api:summary><api:params><api:param name="uri" type="xs:string"><api:param-description>
    The URI of the directory to be deleted.
  </api:param-description><api:param-name>uri</api:param-name><api:param-type>String</api:param-type></api:param></api:params><api:return>null</api:return><api:usage>
  <p xmlns="http://www.w3.org/1999/xhtml">If you delete a directory, the directory and all of its children
  and descendants (recursively)
  are deleted, including all child documents and directories. A child
  document or directory of a given directory is one whose URI begins with
  the same string as the directory URI.</p>
</api:usage><api:example class="javascript"><pre xml:space="preserve" xmlns="http://www.w3.org/1999/xhtml">
declareUpdate();
xdmp.directoryDelete("http://example.com/");
</pre></api:example></api:function></api:function-page>