diff gnv-artifacts/src/main/java/de/intevation/gnv/utils/ExclusiveExec.java @ 806:2cea76f1112e

Added Javadoc in utils package. gnv-artifacts/trunk@888 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Ingo Weinzierl <ingo.weinzierl@intevation.de>
date Thu, 08 Apr 2010 13:10:39 +0000
parents c4156275c1e1
children 22c18083225e
line wrap: on
line diff
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/utils/ExclusiveExec.java	Thu Apr 08 11:31:44 2010 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/utils/ExclusiveExec.java	Thu Apr 08 13:10:39 2010 +0000
@@ -16,13 +16,25 @@
  */
 public final class ExclusiveExec
 {
+    /**
+     * The only instance of this singleton.
+     */
     public static final ExclusiveExec INSTANCE = new ExclusiveExec();
 
     private HashMap tokens;
 
+    /**
+     * This class represents a unique key with a reference counter.
+     */
     public static class UniqueKey {
         Object key;
         int [] refs;
+
+        /**
+         * Constructs a new UniqueKey.
+         *
+         * @param key The key of this unique key.
+         */
         public UniqueKey(Object key) {
             this.key = key;
             refs = new int[1];
@@ -41,7 +53,6 @@
      * block.
      *
      * @param key The key used to identify same threads.
-     *
      * @return UniqueKey. Use this object to call {@link #release(UniqueKey)}
      * at the end of your code being synchronized.
      */

http://dive4elements.wald.intevation.org