[Webfunds-commits] java/webfunds/store Store.java
Ian Grigg
iang@cypherpunks.ai
Fri, 6 Oct 2000 21:16:35 -0400 (AST)
iang 00/10/06 21:16:35
Modified: webfunds/store Store.java
Log:
commentary on syncronsiation issues
Revision Changes Path
1.23 +14 -1 java/webfunds/store/Store.java
Index: Store.java
===================================================================
RCS file: /home/webfunds/cvsroot/java/webfunds/store/Store.java,v
retrieving revision 1.22
retrieving revision 1.23
diff -u -r1.22 -r1.23
--- Store.java 2000/09/30 18:41:17 1.22
+++ Store.java 2000/10/07 01:16:35 1.23
@@ -1,4 +1,4 @@
-/* $Id: Store.java,v 1.22 2000/09/30 18:41:17 iang Exp $
+/* $Id: Store.java,v 1.23 2000/10/07 01:16:35 iang Exp $
*
* Copyright (c) Systemics Ltd 1995-2000 on behalf of
* the WebFunds Development Team. All Rights Reserved.
@@ -95,6 +95,19 @@
public boolean contains(Object o) { return hash.contains(o); }
public boolean containsKey(Object o) { return hash.containsKey(o); }
+ /**
+ * Caller's responsibility to ensure that the value
+ * really needs saving.
+ *
+ * As we mostly deal in copied refs of the Object rather than
+ * copies of the Object, it is the caller's responsibility to
+ * ensure that it needs put'ing.
+ *
+ * There is no support for copies getting out of sync within
+ * separate threads. It would be up to each application to
+ * ensure that only one Object is shared, and that changes to
+ * it are internally syncronised.
+ */
public synchronized Object put(Object key, Object value)
{
Object obj = hash.put(key, value);