You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@james.apache.org by GitBox <gi...@apache.org> on 2022/11/16 09:34:05 UTC

[GitHub] [james-project] Arsnael commented on a diff in pull request #1311: JAMES-3856 RFC-9208 Implement IMAP QUOTA revision

Arsnael commented on code in PR #1311:
URL: https://github.com/apache/james-project/pull/1311#discussion_r1023743034


##########
protocols/imap/src/main/java/org/apache/james/imap/decode/parser/StatusCommandParser.java:
##########
@@ -182,6 +185,29 @@ private StatusDataItems.StatusItem readMessages(ImapRequestLineReader request) t
         return StatusDataItems.StatusItem.MESSAGES;
     }
 
+    private StatusDataItems.StatusItem readDeleted(ImapRequestLineReader request) throws DecodingException {
+        assertChar(request, 'd', 'D');
+        assertChar(request, 'e', 'E');
+        assertChar(request, 'l', 'L');
+        assertChar(request, 'e', 'E');
+        assertChar(request, 't', 'T');
+        assertChar(request, 'e', 'E');
+        assertChar(request, 'd', 'D');
+        char c = request.nextWordChar();
+        if (c == '_') {
+            assertChar(request, '_', '_');

Review Comment:
   should be '-' instead of '_' (line above as well)



##########
protocols/imap/src/main/java/org/apache/james/imap/api/message/StatusDataItems.java:
##########
@@ -70,6 +75,14 @@ public boolean isSize() {
         return statusItems.contains(StatusItem.SIZE);
     }
 
+    public boolean isDeleted() {
+        return statusItems.contains(StatusItem.DELETED);
+    }
+
+    public boolean isDeletedStorage() {
+        return statusItems.contains(StatusItem.DELETED_STORAGE);

Review Comment:
   Disagree too



##########
protocols/imap/src/main/java/org/apache/james/imap/decode/parser/StatusCommandParser.java:
##########
@@ -182,6 +185,29 @@ private StatusDataItems.StatusItem readMessages(ImapRequestLineReader request) t
         return StatusDataItems.StatusItem.MESSAGES;
     }
 
+    private StatusDataItems.StatusItem readDeleted(ImapRequestLineReader request) throws DecodingException {
+        assertChar(request, 'd', 'D');
+        assertChar(request, 'e', 'E');
+        assertChar(request, 'l', 'L');
+        assertChar(request, 'e', 'E');
+        assertChar(request, 't', 'T');
+        assertChar(request, 'e', 'E');
+        assertChar(request, 'd', 'D');
+        char c = request.nextWordChar();
+        if (c == '_') {
+            assertChar(request, '_', '_');
+            assertChar(request, 's', 'S');
+            assertChar(request, 't', 'T');
+            assertChar(request, 'o', 'O');
+            assertChar(request, 'r', 'R');
+            assertChar(request, 'a', 'A');
+            assertChar(request, 'g', 'G');
+            assertChar(request, 'e', 'E');
+            return StatusDataItems.StatusItem.DELETED_STORAGE;

Review Comment:
   Disagree too



##########
protocols/imap/src/main/java/org/apache/james/imap/api/message/StatusDataItems.java:
##########
@@ -30,10 +30,15 @@ public enum StatusItem {
         MESSAGES,
         RECENT,
         UID_NEXT,
-        SIZE,
         UID_VALIDITY,
         UNSEEN,
-        HIGHEST_MODSEQ
+        HIGHEST_MODSEQ,
+        // See https://www.iana.org/go/rfc8438
+        SIZE,
+        // See https://www.rfc-editor.org/rfc/rfc9208.html
+        DELETED,
+        // See https://www.rfc-editor.org/rfc/rfc9208.html
+        DELETED_STORAGE

Review Comment:
   Disagree, this is a constant name.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org
For additional commands, e-mail: notifications-help@james.apache.org