diff --git a/src/java/org/apache/commons/collections/DefaultMapEntry.java b/src/java/org/apache/commons/collections/DefaultMapEntry.java index 7a681319a..c1a6a275b 100644 --- a/src/java/org/apache/commons/collections/DefaultMapEntry.java +++ b/src/java/org/apache/commons/collections/DefaultMapEntry.java @@ -1,5 +1,5 @@ /* - * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/DefaultMapEntry.java,v 1.15 2003/12/05 20:23:57 scolebourne Exp $ + * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/DefaultMapEntry.java,v 1.16 2003/12/06 13:03:15 scolebourne Exp $ * ==================================================================== * * The Apache Software License, Version 1.1 @@ -62,17 +62,16 @@ import java.util.Map; /** * A default implementation of {@link java.util.Map.Entry} * + * @deprecated Use the version in the keyvalue subpackage. * @since Commons Collections 1.0 - * @version $Revision: 1.15 $ $Date: 2003/12/05 20:23:57 $ + * @version $Revision: 1.16 $ $Date: 2003/12/06 13:03:15 $ * * @author James Strachan * @author Michael A. Smith * @author Neil O'Toole * @author Stephen Colebourne - * - * @deprecated Use the version in the keyvalue subpackage. */ -public class DefaultMapEntry implements Map.Entry { +public class DefaultMapEntry implements Map.Entry, KeyValue { /** The key */ private Object key; diff --git a/src/java/org/apache/commons/collections/DoubleOrderedMap.java b/src/java/org/apache/commons/collections/DoubleOrderedMap.java index 26ef819fa..4339e1884 100644 --- a/src/java/org/apache/commons/collections/DoubleOrderedMap.java +++ b/src/java/org/apache/commons/collections/DoubleOrderedMap.java @@ -1,5 +1,5 @@ /* - * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/DoubleOrderedMap.java,v 1.8 2003/11/29 18:05:39 scolebourne Exp $ + * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/DoubleOrderedMap.java,v 1.9 2003/12/06 13:03:15 scolebourne Exp $ * ==================================================================== * * The Apache Software License, Version 1.1 @@ -141,7 +141,7 @@ import java.util.Set; * @see DualTreeBidiMap * @see DualHashBidiMap * @since Commons Collections 2.0 - * @version $Revision: 1.8 $ $Date: 2003/11/29 18:05:39 $ + * @version $Revision: 1.9 $ $Date: 2003/12/06 13:03:15 $ * * @author Marc Johnson */ @@ -1794,7 +1794,7 @@ public final class DoubleOrderedMap extends AbstractMap { } // end private abstract class DoubleOrderedMapIterator // final for performance - private static final class Node implements Map.Entry { + private static final class Node implements Map.Entry, KeyValue { private Comparable[] data; private Node[] leftNode; diff --git a/src/java/org/apache/commons/collections/ReferenceMap.java b/src/java/org/apache/commons/collections/ReferenceMap.java index 5e435f994..b377a672b 100644 --- a/src/java/org/apache/commons/collections/ReferenceMap.java +++ b/src/java/org/apache/commons/collections/ReferenceMap.java @@ -1,5 +1,5 @@ /* - * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/ReferenceMap.java,v 1.18 2003/12/05 20:23:57 scolebourne Exp $ + * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/ReferenceMap.java,v 1.19 2003/12/06 13:03:15 scolebourne Exp $ * ==================================================================== * * The Apache Software License, Version 1.1 @@ -119,7 +119,7 @@ import org.apache.commons.collections.keyvalue.DefaultMapEntry; * * @deprecated Moved to map subpackage. Due to be removed in v4.0. * @since Commons Collections 2.1 - * @version $Revision: 1.18 $ $Date: 2003/12/05 20:23:57 $ + * @version $Revision: 1.19 $ $Date: 2003/12/06 13:03:15 $ * * @author Paul Jack */ @@ -758,7 +758,7 @@ public class ReferenceMap extends AbstractMap { // If getKey() or getValue() returns null, it means // the mapping is stale and should be removed. - private class Entry implements Map.Entry { + private class Entry implements Map.Entry, KeyValue { Object key; Object value; diff --git a/src/java/org/apache/commons/collections/SequencedHashMap.java b/src/java/org/apache/commons/collections/SequencedHashMap.java index 3113e9f8a..d5137df04 100644 --- a/src/java/org/apache/commons/collections/SequencedHashMap.java +++ b/src/java/org/apache/commons/collections/SequencedHashMap.java @@ -1,5 +1,5 @@ /* - * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/SequencedHashMap.java,v 1.22 2003/12/03 11:37:44 scolebourne Exp $ + * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/SequencedHashMap.java,v 1.23 2003/12/06 13:03:15 scolebourne Exp $ * ==================================================================== * * The Apache Software License, Version 1.1 @@ -91,7 +91,7 @@ import org.apache.commons.collections.list.UnmodifiableList; * * @see org.apache.commons.collections.set.ListOrderedSet * @since Commons Collections 2.0 - * @version $Revision: 1.22 $ $Date: 2003/12/03 11:37:44 $ + * @version $Revision: 1.23 $ $Date: 2003/12/06 13:03:15 $ * * @author Michael A. Smith * @author Daniel Rall @@ -104,7 +104,7 @@ public class SequencedHashMap implements Map, Cloneable, Externalizable { * {@link java.util.Map.Entry} that doubles as a node in the linked list * of sequenced mappings. */ - private static class Entry implements Map.Entry { + private static class Entry implements Map.Entry, KeyValue { // Note: This class cannot easily be made clonable. While the actual // implementation of a clone would be simple, defining the semantics is // difficult. If a shallow clone is implemented, then entry.next.prev != diff --git a/src/java/org/apache/commons/collections/StaticBucketMap.java b/src/java/org/apache/commons/collections/StaticBucketMap.java index 793d82e9d..b310a6bf1 100644 --- a/src/java/org/apache/commons/collections/StaticBucketMap.java +++ b/src/java/org/apache/commons/collections/StaticBucketMap.java @@ -1,5 +1,5 @@ /* - * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/StaticBucketMap.java,v 1.13 2003/12/03 15:16:49 scolebourne Exp $ + * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/StaticBucketMap.java,v 1.14 2003/12/06 13:03:15 scolebourne Exp $ * ==================================================================== * * The Apache Software License, Version 1.1 @@ -131,7 +131,7 @@ import java.util.Set; * * @deprecated Moved to map subpackage. Due to be removed in v4.0. * @since Commons Collections 2.1 - * @version $Revision: 1.13 $ $Date: 2003/12/03 15:16:49 $ + * @version $Revision: 1.14 $ $Date: 2003/12/06 13:03:15 $ * * @author Berin Loritsch * @author Gerhard Froehlich @@ -491,7 +491,7 @@ public final class StaticBucketMap implements Map { /** * The Map.Entry for the StaticBucketMap. */ - private static final class Node implements Map.Entry + private static final class Node implements Map.Entry, KeyValue { protected Object key; protected Object value; diff --git a/src/java/org/apache/commons/collections/bidimap/TreeBidiMap.java b/src/java/org/apache/commons/collections/bidimap/TreeBidiMap.java index b79482b97..4e14de912 100644 --- a/src/java/org/apache/commons/collections/bidimap/TreeBidiMap.java +++ b/src/java/org/apache/commons/collections/bidimap/TreeBidiMap.java @@ -1,5 +1,5 @@ /* - * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/bidimap/TreeBidiMap.java,v 1.5 2003/12/05 20:23:58 scolebourne Exp $ + * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/bidimap/TreeBidiMap.java,v 1.6 2003/12/06 13:03:15 scolebourne Exp $ * ==================================================================== * * The Apache Software License, Version 1.1 @@ -67,6 +67,7 @@ import java.util.Set; import org.apache.commons.collections.BidiMap; import org.apache.commons.collections.IteratorUtils; +import org.apache.commons.collections.KeyValue; import org.apache.commons.collections.MapIterator; import org.apache.commons.collections.OrderedBidiMap; import org.apache.commons.collections.OrderedIterator; @@ -107,7 +108,7 @@ import org.apache.commons.collections.keyvalue.UnmodifiableMapEntry; * UnsupportedOperationException on attempts to call that method. * * @since Commons Collections 3.0 (previously DoubleOrderedMap v2.0) - * @version $Revision: 1.5 $ $Date: 2003/12/05 20:23:58 $ + * @version $Revision: 1.6 $ $Date: 2003/12/06 13:03:15 $ * * @author Marc Johnson * @author Stephen Colebourne @@ -1713,7 +1714,7 @@ public class TreeBidiMap implements OrderedBidiMap { /** * A node used to store the data. */ - static class Node implements Map.Entry { + static class Node implements Map.Entry, KeyValue { private Comparable[] data; private Node[] leftNode; diff --git a/src/java/org/apache/commons/collections/keyvalue/AbstractMapEntryDecorator.java b/src/java/org/apache/commons/collections/keyvalue/AbstractMapEntryDecorator.java index 8675438a8..fc72fe9ad 100644 --- a/src/java/org/apache/commons/collections/keyvalue/AbstractMapEntryDecorator.java +++ b/src/java/org/apache/commons/collections/keyvalue/AbstractMapEntryDecorator.java @@ -1,5 +1,5 @@ /* - * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/keyvalue/AbstractMapEntryDecorator.java,v 1.1 2003/12/05 20:23:56 scolebourne Exp $ + * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/keyvalue/AbstractMapEntryDecorator.java,v 1.2 2003/12/06 13:03:15 scolebourne Exp $ * ==================================================================== * * The Apache Software License, Version 1.1 @@ -59,16 +59,18 @@ package org.apache.commons.collections.keyvalue; import java.util.Map; +import org.apache.commons.collections.KeyValue; + /** * Provides a base decorator that allows additional functionality to be added * to a Map Entry. * * @since Commons Collections 3.0 - * @version $Revision: 1.1 $ $Date: 2003/12/05 20:23:56 $ + * @version $Revision: 1.2 $ $Date: 2003/12/06 13:03:15 $ * * @author Stephen Colebourne */ -public abstract class AbstractMapEntryDecorator implements Map.Entry { +public abstract class AbstractMapEntryDecorator implements Map.Entry, KeyValue { /** The Map.Entry to decorate */ protected final Map.Entry entry; @@ -81,7 +83,7 @@ public abstract class AbstractMapEntryDecorator implements Map.Entry { */ public AbstractMapEntryDecorator(Map.Entry entry) { if (entry == null) { - throw new IllegalArgumentException("Map entry must not be null"); + throw new IllegalArgumentException("Map Entry must not be null"); } this.entry = entry; } diff --git a/src/java/org/apache/commons/collections/map/HashedMap.java b/src/java/org/apache/commons/collections/map/HashedMap.java index 73696bc4a..96e04c73a 100644 --- a/src/java/org/apache/commons/collections/map/HashedMap.java +++ b/src/java/org/apache/commons/collections/map/HashedMap.java @@ -1,5 +1,5 @@ /* - * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/map/HashedMap.java,v 1.5 2003/12/03 19:04:41 scolebourne Exp $ + * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/map/HashedMap.java,v 1.6 2003/12/06 13:03:15 scolebourne Exp $ * ==================================================================== * * The Apache Software License, Version 1.1 @@ -72,6 +72,7 @@ import java.util.Set; import org.apache.commons.collections.IterableMap; import org.apache.commons.collections.IteratorUtils; +import org.apache.commons.collections.KeyValue; import org.apache.commons.collections.MapIterator; /** @@ -86,7 +87,7 @@ import org.apache.commons.collections.MapIterator; * methods exposed. * * @since Commons Collections 3.0 - * @version $Revision: 1.5 $ $Date: 2003/12/03 19:04:41 $ + * @version $Revision: 1.6 $ $Date: 2003/12/06 13:03:15 $ * * @author java util HashMap * @author Stephen Colebourne @@ -853,7 +854,7 @@ public class HashedMap implements IterableMap, Serializable, Cloneable { /** * HashEntry */ - protected static class HashEntry implements Map.Entry { + protected static class HashEntry implements Map.Entry, KeyValue { protected HashEntry next; protected int hashCode; protected Object key; diff --git a/src/java/org/apache/commons/collections/map/ReferenceMap.java b/src/java/org/apache/commons/collections/map/ReferenceMap.java index b86c80a48..68ede4d32 100644 --- a/src/java/org/apache/commons/collections/map/ReferenceMap.java +++ b/src/java/org/apache/commons/collections/map/ReferenceMap.java @@ -1,5 +1,5 @@ /* - * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/map/ReferenceMap.java,v 1.2 2003/12/05 20:23:57 scolebourne Exp $ + * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/map/ReferenceMap.java,v 1.3 2003/12/06 13:03:15 scolebourne Exp $ * ==================================================================== * * The Apache Software License, Version 1.1 @@ -76,6 +76,7 @@ import java.util.Map; import java.util.NoSuchElementException; import java.util.Set; +import org.apache.commons.collections.KeyValue; import org.apache.commons.collections.keyvalue.DefaultMapEntry; /** @@ -118,7 +119,7 @@ import org.apache.commons.collections.keyvalue.DefaultMapEntry; * @see java.lang.ref.Reference * * @since Commons Collections 3.0 - * @version $Revision: 1.2 $ $Date: 2003/12/05 20:23:57 $ + * @version $Revision: 1.3 $ $Date: 2003/12/06 13:03:15 $ * * @author Paul Jack */ @@ -757,7 +758,7 @@ public class ReferenceMap extends AbstractMap { // If getKey() or getValue() returns null, it means // the mapping is stale and should be removed. - private class Entry implements Map.Entry { + private class Entry implements Map.Entry, KeyValue { Object key; Object value; diff --git a/src/java/org/apache/commons/collections/map/StaticBucketMap.java b/src/java/org/apache/commons/collections/map/StaticBucketMap.java index 693b509d8..406637175 100644 --- a/src/java/org/apache/commons/collections/map/StaticBucketMap.java +++ b/src/java/org/apache/commons/collections/map/StaticBucketMap.java @@ -1,5 +1,5 @@ /* - * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/map/StaticBucketMap.java,v 1.1 2003/12/03 15:16:49 scolebourne Exp $ + * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/map/StaticBucketMap.java,v 1.2 2003/12/06 13:03:15 scolebourne Exp $ * ==================================================================== * * The Apache Software License, Version 1.1 @@ -66,6 +66,8 @@ import java.util.Map; import java.util.NoSuchElementException; import java.util.Set; +import org.apache.commons.collections.KeyValue; + /** * A StaticBucketMap is an efficient, thread-safe implementation of * java.util.Map that performs well in in a highly @@ -130,7 +132,7 @@ import java.util.Set; * operations will affect the map.

* * @since Commons Collections 3.0 - * @version $Revision: 1.1 $ $Date: 2003/12/03 15:16:49 $ + * @version $Revision: 1.2 $ $Date: 2003/12/06 13:03:15 $ * * @author Berin Loritsch * @author Gerhard Froehlich @@ -478,7 +480,7 @@ public final class StaticBucketMap implements Map { /** * The Map.Entry for the StaticBucketMap. */ - private static final class Node implements Map.Entry { + private static final class Node implements Map.Entry, KeyValue { protected Object key; protected Object value; protected Node next;