Skip to content

Commit b0e91f7

Browse files
committed
📚 Document UIDPLUS commands, response codes, data
* Link to UIDPlusData for commands that can return it: `#append`, `#copy`, and `#move` * Update `#uid_expunge` to avoid "UID set", which has slightly different semantics from "sequence set of UIDs".
1 parent 3c90cec commit b0e91f7

File tree

1 file changed

+12
-9
lines changed

1 file changed

+12
-9
lines changed

lib/net/imap.rb

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1067,9 +1067,10 @@ def status(mailbox, attr)
10671067
# ===== Capabilities
10681068
#
10691069
# If +UIDPLUS+ [RFC4315[https://www.rfc-editor.org/rfc/rfc4315.html]] is
1070-
# supported, the server's response should include a +APPENDUID+ response
1071-
# code with the UIDVALIDITY of the destination mailbox and the assigned UID
1072-
# of the appended message.
1070+
# supported and the destination supports persistent UIDs, the server's
1071+
# response should include an +APPENDUID+ response code with UIDPlusData.
1072+
# This will report the UIDVALIDITY of the destination mailbox and the
1073+
# assigned UID of the appended message.
10731074
#
10741075
#--
10751076
# TODO: add MULTIAPPEND support
@@ -1145,7 +1146,7 @@ def expunge
11451146
#
11461147
# *Note:*
11471148
# >>>
1148-
# Although the command takes a +uid_set+ for its argument, the
1149+
# Although the command takes a set of UIDs for its argument, the
11491150
# server still returns regular EXPUNGE responses, which contain
11501151
# a <em>sequence number</em>. These will be deleted from
11511152
# #responses and this method returns them as an array of
@@ -1322,8 +1323,9 @@ def uid_store(set, attr, flags)
13221323
#
13231324
# If +UIDPLUS+ [RFC4315[https://www.rfc-editor.org/rfc/rfc4315.html]] is
13241325
# supported, the server's response should include a +COPYUID+ response code
1325-
# with the UIDVALIDITY of the destination mailbox, the UID set of the source
1326-
# messages, and the assigned UID set of the moved messages.
1326+
# with UIDPlusData. This will report the UIDVALIDITY of the destination
1327+
# mailbox, the UID set of the source messages, and the assigned UID set of
1328+
# the moved messages.
13271329
def copy(set, mailbox)
13281330
copy_internal("COPY", set, mailbox)
13291331
end
@@ -1355,9 +1357,10 @@ def uid_copy(set, mailbox)
13551357
# [RFC6851[https://tools.ietf.org/html/rfc6851]].
13561358
#
13571359
# If +UIDPLUS+ [RFC4315[https://www.rfc-editor.org/rfc/rfc4315.html]] is
1358-
# also supported, the server's response should include a +COPYUID+ response
1359-
# code with the UIDVALIDITY of the destination mailbox, the UID set of the
1360-
# source messages, and the assigned UID set of the moved messages.
1360+
# supported, the server's response should include a +COPYUID+ response code
1361+
# with UIDPlusData. This will report the UIDVALIDITY of the destination
1362+
# mailbox, the UID set of the source messages, and the assigned UID set of
1363+
# the moved messages.
13611364
#
13621365
def move(set, mailbox)
13631366
copy_internal("MOVE", set, mailbox)

0 commit comments

Comments
 (0)