james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nor...@apache.org
Subject svn commit: r1150460 - /james/mailbox/trunk/api/src/main/java/org/apache/james/mailbox/MailboxPathLocker.java
Date Sun, 24 Jul 2011 18:37:13 GMT
Author: norman
Date: Sun Jul 24 18:37:12 2011
New Revision: 1150460

URL: http://svn.apache.org/viewvc?rev=1150460&view=rev
Log:
Add some javadocs for better description. Part of MAILBOX-110

Modified:
    james/mailbox/trunk/api/src/main/java/org/apache/james/mailbox/MailboxPathLocker.java

Modified: james/mailbox/trunk/api/src/main/java/org/apache/james/mailbox/MailboxPathLocker.java
URL: http://svn.apache.org/viewvc/james/mailbox/trunk/api/src/main/java/org/apache/james/mailbox/MailboxPathLocker.java?rev=1150460&r1=1150459&r2=1150460&view=diff
==============================================================================
--- james/mailbox/trunk/api/src/main/java/org/apache/james/mailbox/MailboxPathLocker.java
(original)
+++ james/mailbox/trunk/api/src/main/java/org/apache/james/mailbox/MailboxPathLocker.java
Sun Jul 24 18:37:12 2011
@@ -19,10 +19,13 @@
 
 package org.apache.james.mailbox;
 
+import java.util.concurrent.locks.ReadWriteLock;
+
 /**
  * The {@link MailboxPathLocker} is responsible to help to synchronize the
- * access to a {@link MailboxPath} and execute an given
- * {@link LockAwareExecution}
+ * access to a {@link MailboxPath} and execute an given {@link LockAwareExecution}
+ * 
+ * Implementations that are not able to handle read / write locks in a different way are
needed to handle all locks as write lock.
  */
 public interface MailboxPathLocker {
 
@@ -35,7 +38,8 @@ public interface MailboxPathLocker {
     
     /**
      * Execute the {@link LockAwareExecution} while holding a lock on the
-     * {@link MailboxPath}. 
+     * {@link MailboxPath}. If writeLock is true the implementation need to make sure that
no other threads can read and write while the lock
+     * is hold. The contract is the same as documented in {@link ReadWriteLock}. 
      * 
      * @param session
      * @param path



---------------------------------------------------------------------
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