diff options
| author | MON KEY | 2012-08-03 10:49:51 +0800 |
|---|---|---|
| committer | Chong Yidong | 2012-08-03 10:49:51 +0800 |
| commit | 41013cb444a24bf51cb1a6f4e96a01a28cdab91e (patch) | |
| tree | 8ce442cd7b7e82660ce23f0515fe8cc61ff9f751 | |
| parent | 0ffee6167f5a90c13fffc53f27a7e13d35475645 (diff) | |
| download | emacs-41013cb444a24bf51cb1a6f4e96a01a28cdab91e.tar.gz emacs-41013cb444a24bf51cb1a6f4e96a01a28cdab91e.zip | |
Doc fixes for imap.el.
* net/imap.el (imap-interactive-login, imap-authenticate)
(imap-mailbox-lsub, imap-mailbox-list)
(imap-mailbox-status-asynch, imap-mailbox-acl-delete)
(imap-fetch, imap-message-flag-permanent-p, imap-envelope-from)
(imap-parse-response): Doc fix.
| -rw-r--r-- | lisp/ChangeLog | 8 | ||||
| -rw-r--r-- | lisp/net/imap.el | 39 |
2 files changed, 29 insertions, 18 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b550c8db7e2..0adcff8e477 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,11 @@ | |||
| 1 | 2012-08-03 MON KEY <monkey@sandpframing.com> | ||
| 2 | |||
| 3 | * net/imap.el (imap-interactive-login, imap-authenticate) | ||
| 4 | (imap-mailbox-lsub, imap-mailbox-list) | ||
| 5 | (imap-mailbox-status-asynch, imap-mailbox-acl-delete) | ||
| 6 | (imap-fetch, imap-message-flag-permanent-p, imap-envelope-from) | ||
| 7 | (imap-parse-response): Doc fix. | ||
| 8 | |||
| 1 | 2012-08-03 João Távora <joaotavora@gmail.com> | 9 | 2012-08-03 João Távora <joaotavora@gmail.com> |
| 2 | 10 | ||
| 3 | * textmodes/tex-mode.el (latex-forward-sexp): Terminate the loop | 11 | * textmodes/tex-mode.el (latex-forward-sexp): Terminate the loop |
diff --git a/lisp/net/imap.el b/lisp/net/imap.el index 853839c2061..531f0730652 100644 --- a/lisp/net/imap.el +++ b/lisp/net/imap.el | |||
| @@ -68,7 +68,7 @@ | |||
| 68 | ;; imap-body-lines | 68 | ;; imap-body-lines |
| 69 | ;; | 69 | ;; |
| 70 | ;; It is my hope that these commands should be pretty self | 70 | ;; It is my hope that these commands should be pretty self |
| 71 | ;; explanatory for someone that know IMAP. All functions have | 71 | ;; explanatory for someone who knows IMAP. All functions have |
| 72 | ;; additional documentation on how to invoke them. | 72 | ;; additional documentation on how to invoke them. |
| 73 | ;; | 73 | ;; |
| 74 | ;; imap.el supports RFC1730/2060/RFC3501 (IMAP4/IMAP4rev1). The implemented | 74 | ;; imap.el supports RFC1730/2060/RFC3501 (IMAP4/IMAP4rev1). The implemented |
| @@ -838,9 +838,10 @@ sure of changing the value of `foo'." | |||
| 838 | 838 | ||
| 839 | (defun imap-interactive-login (buffer loginfunc) | 839 | (defun imap-interactive-login (buffer loginfunc) |
| 840 | "Login to server in BUFFER. | 840 | "Login to server in BUFFER. |
| 841 | LOGINFUNC is passed a username and a password, it should return t if | 841 | Return t if login was successful, nil otherwise. |
| 842 | it where successful authenticating itself to the server, nil otherwise. | 842 | |
| 843 | Returns t if login was successful, nil otherwise." | 843 | LOGINFUNC is passed a username and a password. It should return |
| 844 | t if it successfully authenticates, nil otherwise." | ||
| 844 | (with-current-buffer buffer | 845 | (with-current-buffer buffer |
| 845 | (make-local-variable 'imap-username) | 846 | (make-local-variable 'imap-username) |
| 846 | (make-local-variable 'imap-password) | 847 | (make-local-variable 'imap-password) |
| @@ -1187,11 +1188,12 @@ respond. If BUFFER is nil, the current buffer is used." | |||
| 1187 | 1188 | ||
| 1188 | (defun imap-authenticate (&optional user passwd buffer) | 1189 | (defun imap-authenticate (&optional user passwd buffer) |
| 1189 | "Authenticate to server in BUFFER, using current buffer if nil. | 1190 | "Authenticate to server in BUFFER, using current buffer if nil. |
| 1190 | It uses the authenticator specified when opening the server. If the | 1191 | It uses the authenticator specified when opening the server. |
| 1191 | authenticator requires username/passwords, they are queried from the | 1192 | |
| 1192 | user and optionally stored in the buffer. If USER and/or PASSWD is | 1193 | Optional arguments USER and PASSWD specify the username and |
| 1193 | specified, the user will not be questioned and the username and/or | 1194 | password to use if the authenticator requires a username and/or |
| 1194 | password is remembered in the buffer." | 1195 | password. If omitted or nil, the authenticator may query the |
| 1196 | user for a username and/or password." | ||
| 1195 | (with-current-buffer (or buffer (current-buffer)) | 1197 | (with-current-buffer (or buffer (current-buffer)) |
| 1196 | (if (not (eq imap-state 'nonauth)) | 1198 | (if (not (eq imap-state 'nonauth)) |
| 1197 | (or (eq imap-state 'auth) | 1199 | (or (eq imap-state 'auth) |
| @@ -1475,7 +1477,7 @@ If BUFFER is nil the current buffer is assumed." | |||
| 1475 | (defun imap-mailbox-lsub (&optional root reference add-delimiter buffer) | 1477 | (defun imap-mailbox-lsub (&optional root reference add-delimiter buffer) |
| 1476 | "Return a list of subscribed mailboxes on server in BUFFER. | 1478 | "Return a list of subscribed mailboxes on server in BUFFER. |
| 1477 | If ROOT is non-nil, only list matching mailboxes. If ADD-DELIMITER is | 1479 | If ROOT is non-nil, only list matching mailboxes. If ADD-DELIMITER is |
| 1478 | non-nil, a hierarchy delimiter is added to root. REFERENCE is a | 1480 | non-nil, a hierarchy delimiter is added to root. REFERENCE is an |
| 1479 | implementation-specific string that has to be passed to lsub command." | 1481 | implementation-specific string that has to be passed to lsub command." |
| 1480 | (with-current-buffer (or buffer (current-buffer)) | 1482 | (with-current-buffer (or buffer (current-buffer)) |
| 1481 | ;; Make sure we know the hierarchy separator for root's hierarchy | 1483 | ;; Make sure we know the hierarchy separator for root's hierarchy |
| @@ -1499,7 +1501,7 @@ implementation-specific string that has to be passed to lsub command." | |||
| 1499 | (defun imap-mailbox-list (root &optional reference add-delimiter buffer) | 1501 | (defun imap-mailbox-list (root &optional reference add-delimiter buffer) |
| 1500 | "Return a list of mailboxes matching ROOT on server in BUFFER. | 1502 | "Return a list of mailboxes matching ROOT on server in BUFFER. |
| 1501 | If ADD-DELIMITER is non-nil, a hierarchy delimiter is added to | 1503 | If ADD-DELIMITER is non-nil, a hierarchy delimiter is added to |
| 1502 | root. REFERENCE is a implementation-specific string that has to be | 1504 | root. REFERENCE is an implementation-specific string that has to be |
| 1503 | passed to list command." | 1505 | passed to list command." |
| 1504 | (with-current-buffer (or buffer (current-buffer)) | 1506 | (with-current-buffer (or buffer (current-buffer)) |
| 1505 | ;; Make sure we know the hierarchy separator for root's hierarchy | 1507 | ;; Make sure we know the hierarchy separator for root's hierarchy |
| @@ -1559,7 +1561,7 @@ returned, if ITEMS is a symbol only its value is returned." | |||
| 1559 | (imap-mailbox-get items mailbox))))) | 1561 | (imap-mailbox-get items mailbox))))) |
| 1560 | 1562 | ||
| 1561 | (defun imap-mailbox-status-asynch (mailbox items &optional buffer) | 1563 | (defun imap-mailbox-status-asynch (mailbox items &optional buffer) |
| 1562 | "Send status item request ITEM on MAILBOX to server in BUFFER. | 1564 | "Send status item requests ITEMS on MAILBOX to server in BUFFER. |
| 1563 | ITEMS can be a symbol or a list of symbols, valid symbols are one of | 1565 | ITEMS can be a symbol or a list of symbols, valid symbols are one of |
| 1564 | the STATUS data items -- i.e. 'messages, 'recent, 'uidnext, 'uidvalidity | 1566 | the STATUS data items -- i.e. 'messages, 'recent, 'uidnext, 'uidvalidity |
| 1565 | or 'unseen. The IMAP command tag is returned." | 1567 | or 'unseen. The IMAP command tag is returned." |
| @@ -1596,7 +1598,7 @@ or 'unseen. The IMAP command tag is returned." | |||
| 1596 | rights)))))) | 1598 | rights)))))) |
| 1597 | 1599 | ||
| 1598 | (defun imap-mailbox-acl-delete (identifier &optional mailbox buffer) | 1600 | (defun imap-mailbox-acl-delete (identifier &optional mailbox buffer) |
| 1599 | "Remove any <identifier,rights> pair for IDENTIFIER in MAILBOX from server in BUFFER." | 1601 | "Remove <id,rights> pairs for IDENTIFIER from MAILBOX on server in BUFFER." |
| 1600 | (let ((mailbox (imap-utf7-encode mailbox))) | 1602 | (let ((mailbox (imap-utf7-encode mailbox))) |
| 1601 | (with-current-buffer (or buffer (current-buffer)) | 1603 | (with-current-buffer (or buffer (current-buffer)) |
| 1602 | (imap-ok-p | 1604 | (imap-ok-p |
| @@ -1642,8 +1644,8 @@ or 'unseen. The IMAP command tag is returned." | |||
| 1642 | 1644 | ||
| 1643 | (defun imap-fetch (uids props &optional receive nouidfetch buffer) | 1645 | (defun imap-fetch (uids props &optional receive nouidfetch buffer) |
| 1644 | "Fetch properties PROPS from message set UIDS from server in BUFFER. | 1646 | "Fetch properties PROPS from message set UIDS from server in BUFFER. |
| 1645 | UIDS can be a string, number or a list of numbers. If RECEIVE | 1647 | UIDS can be a string, number or a list of numbers. If RECEIVE is |
| 1646 | is non-nil return these properties." | 1648 | non-nil, return these properties." |
| 1647 | (with-current-buffer (or buffer (current-buffer)) | 1649 | (with-current-buffer (or buffer (current-buffer)) |
| 1648 | (when (imap-ok-p (imap-send-command-wait | 1650 | (when (imap-ok-p (imap-send-command-wait |
| 1649 | (format "%sFETCH %s %s" (if nouidfetch "" "UID ") | 1651 | (format "%sFETCH %s %s" (if nouidfetch "" "UID ") |
| @@ -1743,7 +1745,8 @@ is non-nil return these properties." | |||
| 1743 | (imap-mailbox-get-1 'search imap-current-mailbox))))) | 1745 | (imap-mailbox-get-1 'search imap-current-mailbox))))) |
| 1744 | 1746 | ||
| 1745 | (defun imap-message-flag-permanent-p (flag &optional mailbox buffer) | 1747 | (defun imap-message-flag-permanent-p (flag &optional mailbox buffer) |
| 1746 | "Return t if FLAG can be permanently (between IMAP sessions) saved on articles, in MAILBOX on server in BUFFER." | 1748 | "Return t if FLAG can be permanently saved on articles. |
| 1749 | MAILBOX specifies a mailbox on the server in BUFFER." | ||
| 1747 | (with-current-buffer (or buffer (current-buffer)) | 1750 | (with-current-buffer (or buffer (current-buffer)) |
| 1748 | (or (member "\\*" (imap-mailbox-get 'permanentflags mailbox)) | 1751 | (or (member "\\*" (imap-mailbox-get 'permanentflags mailbox)) |
| 1749 | (member flag (imap-mailbox-get 'permanentflags mailbox))))) | 1752 | (member flag (imap-mailbox-get 'permanentflags mailbox))))) |
| @@ -1918,7 +1921,7 @@ on failure." | |||
| 1918 | 0)) | 1921 | 0)) |
| 1919 | 1922 | ||
| 1920 | (defun imap-envelope-from (from) | 1923 | (defun imap-envelope-from (from) |
| 1921 | "Return a from string line." | 1924 | "Return a FROM string line." |
| 1922 | (and from | 1925 | (and from |
| 1923 | (concat (aref from 0) | 1926 | (concat (aref from 0) |
| 1924 | (if (aref from 0) " <") | 1927 | (if (aref from 0) " <") |
| @@ -2285,7 +2288,7 @@ Return nil if no complete line has arrived." | |||
| 2285 | ;; ; capability. | 2288 | ;; ; capability. |
| 2286 | 2289 | ||
| 2287 | (defun imap-parse-response () | 2290 | (defun imap-parse-response () |
| 2288 | "Parse a IMAP command response." | 2291 | "Parse an IMAP command response." |
| 2289 | (let (token) | 2292 | (let (token) |
| 2290 | (case (setq token (read (current-buffer))) | 2293 | (case (setq token (read (current-buffer))) |
| 2291 | (+ (setq imap-continuation | 2294 | (+ (setq imap-continuation |