X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=src%2Forg%2Fibex%2Futil%2FHash.java;h=f0a03537f88ecd91053d9c280fd862e3e44d8173;hb=1f80106afa0f0eb6f12544c75304f2084aca6499;hp=4b3887065202aba7e865fc2b54055303e64bc249;hpb=3a85dab61cef1346315ca40d3004f8772815127f;p=org.ibex.util.git diff --git a/src/org/ibex/util/Hash.java b/src/org/ibex/util/Hash.java index 4b38870..f0a0353 100644 --- a/src/org/ibex/util/Hash.java +++ b/src/org/ibex/util/Hash.java @@ -1,9 +1,6 @@ -// Copyright (C) 2003 Adam Megacz all rights reserved. -// -// You may modify, copy, and redistribute this code under the terms of -// the GNU Library Public License version 2.1, with the exception of -// the portion of clause 6a after the semicolon (aka the "obnoxious -// relink clause") +// Copyright 2000-2005 the Contributors, as shown in the revision logs. +// Licensed under the Apache Public Source License 2.0 ("the License"). +// You may not use this file except in compliance with the License. package org.ibex.util; @@ -16,13 +13,17 @@ import java.util.*; * * Not threadsafe. */ -public class Hash { +public class Hash implements java.io.Serializable { + + public static final long serialVersionUID = 8177551301264350283L; + /** 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;