use it as a the path for loading message entities.
* elmo-dop.el (elmo-folder-status-dop): Use elmo-msgdb-list-messages.
+2003-08-07 Yuuichi Teranishi <teranisi@gohome.org>
+
+ * elmo-msgdb.el (elmo-msgdb-list-messages): If argument is a string,
+ use it as a the path for loading message entities.
+
+ * elmo-dop.el (elmo-folder-status-dop): Use elmo-msgdb-list-messages.
+
2003-08-05 Yuuichi Teranishi <teranisi@gohome.org>
* elmo-filter.el (elmo-folder-set-message-modified): Set
;;; Execute as subsutitute for plugged operation.
(defun elmo-folder-status-dop (folder)
- (let* ((number-alist (elmo-msgdb-number-load
- (elmo-folder-msgdb-path folder)))
- (number-list (mapcar 'car number-alist))
- (spool-folder (elmo-dop-spool-folder folder))
- spool-length
- (i 0)
- max-num)
+ (let ((number-list (elmo-msgdb-list-messages
+ (elmo-folder-msgdb-path folder)))
+ (spool-folder (elmo-dop-spool-folder folder))
+ spool-length
+ (i 0)
+ max-num)
(setq spool-length (or (car (if (elmo-folder-exists-p spool-folder)
(elmo-folder-status spool-folder))) 0))
(setq max-num
(elmo-msgdb-make-index msgdb)
msgdb))
-(defun elmo-msgdb-list-messages (msgdb)
- "List message numbers in the MSGDB."
+(defun elmo-msgdb-list-messages (msgdb-or-path)
+ "Return a list of message numbers in the msgdb.
+If MSGDB-OR-PATH is a msgdb structure, use it as a msgdb.
+If argument is a string, use it as a path to load message entities."
(mapcar 'elmo-msgdb-overview-entity-get-number
- (elmo-msgdb-get-overview msgdb)))
+ (if (stringp msgdb)
+ (elmo-msgdb-overview-load msgdb)
+ (elmo-msgdb-get-overview msgdb))))
(defsubst elmo-msgdb-get-mark (msgdb number)
"Get mark string from MSGDB which corresponds to the message with NUMBER."