[Swift-commit] r2105 - trunk/src/org/griphyn/vdl/karajan/lib/cache

noreply at svn.ci.uchicago.edu noreply at svn.ci.uchicago.edu
Wed Jul 9 14:56:04 CDT 2008


Author: hategan
Date: 2008-07-09 14:56:04 -0500 (Wed, 09 Jul 2008)
New Revision: 2105

Modified:
   trunk/src/org/griphyn/vdl/karajan/lib/cache/VDLFileCache.java
Log:
automatic formating messes things up at times

Modified: trunk/src/org/griphyn/vdl/karajan/lib/cache/VDLFileCache.java
===================================================================
--- trunk/src/org/griphyn/vdl/karajan/lib/cache/VDLFileCache.java	2008-07-09 19:53:45 UTC (rev 2104)
+++ trunk/src/org/griphyn/vdl/karajan/lib/cache/VDLFileCache.java	2008-07-09 19:56:04 UTC (rev 2105)
@@ -13,47 +13,45 @@
  * 
  * The logical flow of the process is as follows:
  * <ol>
- * <li> The client code wants to cache an entry
- * <li> The client code calls <code>addAndLockEntry</code> with the respective
- * entry. This will lock the entry for both usage and processing. The
- * <code>addAndLockEntry</code> method returns a <code>CacheReturn</code>
- * object (let's call it <code>status</code>), which can signal a few things:
+ * 	<li> The client code wants to cache an entry
+ * 	<li> The client code calls <code>addAndLockEntry</code> with the respective
+ * 		entry. This will lock the entry for both usage and processing. The
+ * 		<code>addAndLockEntry</code> method returns a <code>CacheReturn</code>
+ * 		object (let's call it <code>status</code>), which can signal a few things:
  * 
- * <ol>
- * <li> If the entry is already cached, then <code>status.alreadyCached</code>
- * will be <code>true</code>, and <code>status.cached</code> will contain
- * the cached entry. The client code should check then if the already cached
- * entry is locked for processing by calling the
- * <code>isLockedForProcessing</code> method, and:
- * <ol>
- * <li> If the entry is locked for processing, the client code should add a
- * listener to the entry in order to get notified when the processing is
- * complete (<code>status.cached.addProcessingListener</code>). Upon receipt
- * of notification of processing completion, the client code should retry
- * calling the addAndLockEntry, since the processing may have involved the
- * removal of the file from the cache.
- * <li> If the entry is not locked for processing, the client code can assume
- * that the entry is correctly present in the physical cache
+ * 		<ol>
+ * 			<li> If the entry is already cached, then <code>status.alreadyCached</code>
+ * 				will be <code>true</code>, and <code>status.cached</code> will contain
+ * 				the cached entry. The client code should check then if the already cached
+ * 				entry is locked for processing by calling the
+ * 				<code>isLockedForProcessing</code> method, and:
+ * 				<ol>
+ * 					<li> If the entry is locked for processing, the client code should add a
+ * 						listener to the entry in order to get notified when the processing is
+ * 						complete (<code>status.cached.addProcessingListener</code>). Upon receipt
+ * 						of notification of processing completion, the client code should retry
+ * 						calling the addAndLockEntry, since the processing may have involved the
+ * 						removal of the file from the cache.
+ * 					<li> If the entry is not locked for processing, the client code can assume
+ * 						that the entry is correctly present in the physical cache
+ * 				</ol>
+ * 			<li> If the entry is not cached (<code>status.alreadyCached</code> is <code>false</code>), 
+ * 				then the client code must physically put the entry into the cache, after which it 
+ * 				shoult call <code>unlockFromProcessing</code>
+ * 			<li> Removal requests are listed in the <code>status.remove</code> list. The entries
+ * 				returned must be already locked for processing by the cache implementation, in 
+ * 				order to prevent them from being used by other threads. 
+ * 				The application code should physically remove such entries from the cache, and 
+ * 				then call <code>fileRemoved</code>.
+ * 		</ol> 
+ * 	<li> The client code uses the cached data
+ * 	<li> The client code calls <code>unlockEntry</code> to signal that the data is not needed by the
+ * 		application any more, and it can eventually be removed from the cache
  * </ol>
- * <li> If the entry is not cached (<code>status.alreadyCached</code> is
- * <code>false</code>), then the client code must physically put the entry
- * into the cache, after which it shoult call <code>unlockFromProcessing</code>
- * <li> Removal requests are listed in the <code>status.remove</code> list.
- * The entries returned must be already locked for processing by the cache
- * implementation, in order to prevent them from being used by other threads.
- * The application code should physically remove such entries from the cache,
- * and then call <code>fileRemoved</code>.
- * </ol>
- * <li> The client code uses the cached data
- * <li> The client code calls <code>unlockEntry</code> to signal that the data
- * is not needed by the application any more, and it can eventually be removed
- * from the cache
- * </ol>
  * 
- * Alternatively, the <code>addEntry</code> method can be used to add an entry
- * to the cache without locking it in any way. This is intended for cases when
- * the client code does not have direct control over what goes into the physical
- * cache.
+ * Alternatively, the <code>addEntry</code> method can be used to add an entry to the cache without
+ * locking it in any way. This is intended for cases when the client code does not have direct control
+ * over what goes into the physical cache.
  */
 public interface VDLFileCache {
 	/**
@@ -103,16 +101,16 @@
 	 * the entry was locked for being removed).
 	 */
 	CacheReturn unlockFromProcessing(File f);
-
+	
 	/**
 	 * Returns a collection of {@link File} objects representing the files
 	 * stored in the cache for the specified host
 	 */
 	Collection getFiles(Object host);
-
+	
 	/**
-	 * Returns a collection of {@link String} objects representing the file
-	 * paths stored in the cache for the specified host
+	 * Returns a collection of {@link String} objects representing the file paths
+	 * stored in the cache for the specified host
 	 */
 	Collection getPaths(Object host);
 }




More information about the Swift-commit mailing list