if (recursive) allDocs(broker, docs, checkPermissions);
subColls = subcollections.keys(); } catch (LockException e) { LOG.warn(e.getMessage(), e); } finally { getLock().release(); } if (recursive && subColls != null) {  for (int i = 0; i < subColls.size(); i++) { XmldbURI childName = (XmldbURI) subColls.get(i); Collection child = broker.openCollection(path.appendInternal(childName), Lock.NO_LOCK);  if (child != null) child.allDocs(broker, docs, recursive, checkPermissions); }
    public DocumentSet allDocs(DBBroker broker, DocumentSet docs,            boolean recursive, boolean checkPermissions) {        if (permissions.validate(broker.getUser(), Permission.READ)) {            CollectionCache cache = broker.getBrokerPool().getCollectionsCache();            synchronized (cache) {                getDocuments(broker, docs, checkPermissions);                if (recursive)                    allDocs(broker, docs, checkPermissions);            }        }        return docs;    }