james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From btell...@apache.org
Subject svn commit: r1685940 - in /james/mailbox/trunk/cassandra/src/main/java/org/apache/james/mailbox/cassandra: CassandraMailboxSessionMapperFactory.java mail/CassandraMessageMapper.java
Date Wed, 17 Jun 2015 08:36:42 GMT
Author: btellier
Date: Wed Jun 17 08:36:42 2015
New Revision: 1685940

URL: http://svn.apache.org/r1685940
Log:
Use interface instead of class

Modified:
    james/mailbox/trunk/cassandra/src/main/java/org/apache/james/mailbox/cassandra/CassandraMailboxSessionMapperFactory.java
    james/mailbox/trunk/cassandra/src/main/java/org/apache/james/mailbox/cassandra/mail/CassandraMessageMapper.java

Modified: james/mailbox/trunk/cassandra/src/main/java/org/apache/james/mailbox/cassandra/CassandraMailboxSessionMapperFactory.java
URL: http://svn.apache.org/viewvc/james/mailbox/trunk/cassandra/src/main/java/org/apache/james/mailbox/cassandra/CassandraMailboxSessionMapperFactory.java?rev=1685940&r1=1685939&r2=1685940&view=diff
==============================================================================
--- james/mailbox/trunk/cassandra/src/main/java/org/apache/james/mailbox/cassandra/CassandraMailboxSessionMapperFactory.java
(original)
+++ james/mailbox/trunk/cassandra/src/main/java/org/apache/james/mailbox/cassandra/CassandraMailboxSessionMapperFactory.java
Wed Jun 17 08:36:42 2015
@@ -24,7 +24,6 @@ import java.util.UUID;
 import org.apache.james.mailbox.MailboxSession;
 import org.apache.james.mailbox.cassandra.mail.CassandraMailboxMapper;
 import org.apache.james.mailbox.cassandra.mail.CassandraMessageMapper;
-import org.apache.james.mailbox.cassandra.mail.CassandraUidProvider;
 import org.apache.james.mailbox.cassandra.user.CassandraSubscriptionMapper;
 import org.apache.james.mailbox.store.MailboxSessionMapperFactory;
 import org.apache.james.mailbox.store.mail.MailboxMapper;
@@ -42,11 +41,11 @@ public class CassandraMailboxSessionMapp
     private static final int DEFAULT_MAX_RETRY = 1000;
 
     private Session session;
-    private CassandraUidProvider uidProvider;
+    private UidProvider<UUID> uidProvider;
     private ModSeqProvider<UUID> modSeqProvider;
     private int maxRetry;
 
-    public CassandraMailboxSessionMapperFactory(CassandraUidProvider uidProvider, ModSeqProvider<UUID>
modSeqProvider, Session session) {
+    public CassandraMailboxSessionMapperFactory(UidProvider<UUID> uidProvider, ModSeqProvider<UUID>
modSeqProvider, Session session) {
         this.uidProvider = uidProvider;
         this.modSeqProvider = modSeqProvider;
         this.session = session;

Modified: james/mailbox/trunk/cassandra/src/main/java/org/apache/james/mailbox/cassandra/mail/CassandraMessageMapper.java
URL: http://svn.apache.org/viewvc/james/mailbox/trunk/cassandra/src/main/java/org/apache/james/mailbox/cassandra/mail/CassandraMessageMapper.java?rev=1685940&r1=1685939&r2=1685940&view=diff
==============================================================================
--- james/mailbox/trunk/cassandra/src/main/java/org/apache/james/mailbox/cassandra/mail/CassandraMessageMapper.java
(original)
+++ james/mailbox/trunk/cassandra/src/main/java/org/apache/james/mailbox/cassandra/mail/CassandraMessageMapper.java
Wed Jun 17 08:36:42 2015
@@ -28,12 +28,13 @@ import static com.datastax.driver.core.q
 import static com.datastax.driver.core.querybuilder.QueryBuilder.insertInto;
 import static com.datastax.driver.core.querybuilder.QueryBuilder.lt;
 import static com.datastax.driver.core.querybuilder.QueryBuilder.select;
-import static com.datastax.driver.core.querybuilder.QueryBuilder.update;
 import static com.datastax.driver.core.querybuilder.QueryBuilder.set;
+import static com.datastax.driver.core.querybuilder.QueryBuilder.update;
 import static org.apache.james.mailbox.cassandra.table.CassandraMessageTable.BODY_CONTENT;
 import static org.apache.james.mailbox.cassandra.table.CassandraMessageTable.BODY_OCTECTS;
 import static org.apache.james.mailbox.cassandra.table.CassandraMessageTable.BODY_START_OCTET;
 import static org.apache.james.mailbox.cassandra.table.CassandraMessageTable.FIELDS;
+import static org.apache.james.mailbox.cassandra.table.CassandraMessageTable.FLAG_VERSION;
 import static org.apache.james.mailbox.cassandra.table.CassandraMessageTable.FULL_CONTENT_OCTETS;
 import static org.apache.james.mailbox.cassandra.table.CassandraMessageTable.HEADER_CONTENT;
 import static org.apache.james.mailbox.cassandra.table.CassandraMessageTable.IMAP_UID;
@@ -52,7 +53,6 @@ import static org.apache.james.mailbox.c
 import static org.apache.james.mailbox.cassandra.table.CassandraMessageTable.Flag.RECENT;
 import static org.apache.james.mailbox.cassandra.table.CassandraMessageTable.Flag.SEEN;
 import static org.apache.james.mailbox.cassandra.table.CassandraMessageTable.Flag.USER;
-import static org.apache.james.mailbox.cassandra.table.CassandraMessageTable.FLAG_VERSION;
 
 import java.io.IOException;
 import java.io.InputStream;
@@ -66,7 +66,6 @@ import javax.mail.Flags;
 import javax.mail.Flags.Flag;
 import javax.mail.util.SharedByteArrayInputStream;
 
-import com.datastax.driver.core.querybuilder.Update;
 import org.apache.james.mailbox.MailboxSession;
 import org.apache.james.mailbox.cassandra.table.CassandraMailboxCountersTable;
 import org.apache.james.mailbox.cassandra.table.CassandraMessageTable;
@@ -114,15 +113,15 @@ public class CassandraMessageMapper impl
 
     private final static int DEFAULT_MAX_RETRIES = 10000;
 
-    public CassandraMessageMapper(Session session, CassandraUidProvider uidProvider, ModSeqProvider<UUID>
modSeqProvider) {
+    public CassandraMessageMapper(Session session, UidProvider<UUID> uidProvider, ModSeqProvider<UUID>
modSeqProvider) {
         this(session, uidProvider, modSeqProvider, null, DEFAULT_MAX_RETRIES);
     }
 
-    public CassandraMessageMapper(Session session, CassandraUidProvider uidProvider, ModSeqProvider<UUID>
modSeqProvider, MailboxSession mailboxSession) {
+    public CassandraMessageMapper(Session session, UidProvider<UUID> uidProvider, ModSeqProvider<UUID>
modSeqProvider, MailboxSession mailboxSession) {
         this(session, uidProvider, modSeqProvider, mailboxSession, DEFAULT_MAX_RETRIES);
     }
 
-    public CassandraMessageMapper(Session session, CassandraUidProvider uidProvider, ModSeqProvider<UUID>
modSeqProvider, MailboxSession mailboxSession, int maxRetries) {
+    public CassandraMessageMapper(Session session, UidProvider<UUID> uidProvider, ModSeqProvider<UUID>
modSeqProvider, MailboxSession mailboxSession, int maxRetries) {
         this.session = session;
         this.uidProvider = uidProvider;
         this.modSeqProvider = modSeqProvider;



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


Mime
View raw message