Function: org-persist--find-index
org-persist--find-index is a byte-compiled function defined in
org-persist.el.gz.
Signature
(org-persist--find-index COLLECTION)
Documentation
Find COLLECTION in org-persist--index.
Source Code
;; Defined in /usr/src/emacs/lisp/org/org-persist.el.gz
(defun org-persist--find-index (collection)
"Find COLLECTION in `org-persist--index'."
(org-persist-collection-let collection
(and org-persist--index-hash
(catch :found
(dolist (cont
(if (listp (car container)) ; container group
(cons container container)
(list container)))
(let ((r (or (gethash (cons cont associated) org-persist--index-hash)
(and path (gethash (cons cont (list :file path)) org-persist--index-hash))
(and inode (gethash (cons cont (list :inode inode)) org-persist--index-hash))
(and hash (gethash (cons cont (list :hash hash)) org-persist--index-hash))
(and key (gethash (cons cont (list :key key)) org-persist--index-hash)))))
(when (and r
;; Every element in container group of
;; COLLECTION matches returned CONTAINER.
(seq-every-p
(lambda (cont)
(org-persist-collection-let r
(member cont container)))
(if (listp (car container))
container
(list container))))
(throw :found r))))))))