hacks ot make Hash serializable
[org.ibex.util.git] / src / org / ibex / util / Hash.java
index 4b38870..6952e82 100644 (file)
@@ -16,13 +16,14 @@ import java.util.*;
  *
  *  Not threadsafe.
  */
-public class Hash {
+public class Hash implements java.io.Serializable {
     /** this object is inserted as key in a slot when the
      *  corresponding value is removed -- this ensures that the
      *  probing sequence for any given key remains the same even if
      *  other keys are removed.
      */
-    private static Object placeholder = new Object();
+    // FIXME: this should have been static except that that makes it nonserializable
+    private Object placeholder = new java.io.Serializable() { };
 
     /** the number of entries with at least one non-null key */
     private int usedslots = 0;