You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@james.apache.org by bt...@apache.org on 2023/04/04 02:45:51 UTC

[james-project] 03/09: [REFACTORING] Remove unused methods in MessageSearches

This is an automated email from the ASF dual-hosted git repository.

btellier pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/james-project.git

commit f2f0496d519be9a392d3e8841ba74068497cf985
Author: Benoit Tellier <bt...@linagora.com>
AuthorDate: Wed Jan 11 15:38:16 2023 +0700

    [REFACTORING] Remove unused methods in MessageSearches
---
 .../apache/james/mailbox/store/search/MessageSearches.java | 14 --------------
 1 file changed, 14 deletions(-)

diff --git a/mailbox/store/src/main/java/org/apache/james/mailbox/store/search/MessageSearches.java b/mailbox/store/src/main/java/org/apache/james/mailbox/store/search/MessageSearches.java
index 4d59dfcb73..d09ccd5f13 100644
--- a/mailbox/store/src/main/java/org/apache/james/mailbox/store/search/MessageSearches.java
+++ b/mailbox/store/src/main/java/org/apache/james/mailbox/store/search/MessageSearches.java
@@ -60,12 +60,10 @@ import org.apache.james.mime4j.dom.address.Group;
 import org.apache.james.mime4j.dom.address.Mailbox;
 import org.apache.james.mime4j.dom.address.MailboxList;
 import org.apache.james.mime4j.dom.datetime.DateTime;
-import org.apache.james.mime4j.field.Fields;
 import org.apache.james.mime4j.field.address.AddressFormatter;
 import org.apache.james.mime4j.field.address.LenientAddressParser;
 import org.apache.james.mime4j.field.datetime.parser.DateTimeParser;
 import org.apache.james.mime4j.field.datetime.parser.ParseException;
-import org.apache.james.mime4j.message.HeaderImpl;
 import org.apache.james.mime4j.util.MimeUtil;
 import org.apache.james.mime4j.utils.search.MessageMatcher;
 import org.slf4j.Logger;
@@ -270,18 +268,6 @@ public class MessageSearches implements Iterable<SimpleMessageSearchIndex.Search
             return Stream.of();
         }
     }
-
-    private void addFrom(HeaderImpl headerImpl, MailboxList from) {
-        if (from != null) {
-            headerImpl.addField(Fields.from(Lists.newArrayList(from.iterator())));
-        }
-    }
-
-    private void addAddressList(HeaderImpl headerImpl, AddressList addressList) {
-        if (addressList != null) {
-            headerImpl.addField(Fields.to(Lists.newArrayList(addressList.iterator())));
-        }
-    }
     
     private boolean matches(SearchQuery.ConjunctionCriterion criterion, MailboxMessage message,
             final Collection<MessageUid> recentMessageUids) throws MailboxException {


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