git-svn-id: https://svn.apache.org/repos/asf/jakarta/commons/proper/collections/trunk@131496 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Phil Steitz 2004-01-02 01:36:52 +00:00
parent 75a4b6a411
commit 08a95179a6
12 changed files with 51 additions and 60 deletions

View File

@ -1,5 +1,5 @@
/*
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/BinaryHeap.java,v 1.17 2004/01/01 23:56:51 psteitz Exp $
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/BinaryHeap.java,v 1.18 2004/01/02 01:36:51 psteitz Exp $
* ====================================================================
*
* The Apache Software License, Version 1.1
@ -92,7 +92,7 @@ import java.util.NoSuchElementException;
* </pre>
*
* @since Commons Collections 1.0
* @version $Revision: 1.17 $ $Date: 2004/01/01 23:56:51 $
* @version $Revision: 1.18 $ $Date: 2004/01/02 01:36:51 $
*
* @author Peter Donald
* @author Ram Chidambaram
@ -419,7 +419,7 @@ public final class BinaryHeap extends AbstractCollection
* <p>
* Assume it is a maximum heap.
*
* @param element the element
* @param index the index of the element to be percolated up
*/
protected void percolateUpMaxHeap(final int index) {
int hole = index;

View File

@ -1,10 +1,10 @@
/*
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/bag/AbstractMapBag.java,v 1.9 2003/12/28 16:36:48 scolebourne Exp $
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/bag/AbstractMapBag.java,v 1.10 2004/01/02 01:36:51 psteitz Exp $
* ====================================================================
*
* The Apache Software License, Version 1.1
*
* Copyright (c) 2002-2003 The Apache Software Foundation. All rights
* Copyright (c) 2002-2004 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -79,7 +79,7 @@ import org.apache.commons.collections.set.UnmodifiableSet;
* the number of occurrences of that element in the bag.
*
* @since Commons Collections 3.0 (previously DefaultMapBag v2.0)
* @version $Revision: 1.9 $ $Date: 2003/12/28 16:36:48 $
* @version $Revision: 1.10 $ $Date: 2004/01/02 01:36:51 $
*
* @author Chuck Burdick
* @author Michael A. Smith
@ -100,7 +100,6 @@ public abstract class AbstractMapBag implements Bag {
/**
* Constructor needed for subclass serialisation.
*
* @param map the map to assign
*/
protected AbstractMapBag() {
super();
@ -542,7 +541,7 @@ public abstract class AbstractMapBag implements Bag {
* This Bag equals another Bag if it contains the same number of occurances of
* the same elements.
*
* @param obj the Bag to compare to
* @param object the Bag to compare to
* @return true if equal
*/
public boolean equals(Object object) {

View File

@ -1,10 +1,10 @@
/*
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/bidimap/DualTreeBidiMap.java,v 1.7 2003/12/29 00:38:08 scolebourne Exp $
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/bidimap/DualTreeBidiMap.java,v 1.8 2004/01/02 01:36:51 psteitz Exp $
* ====================================================================
*
* The Apache Software License, Version 1.1
*
* Copyright (c) 2001-2003 The Apache Software Foundation. All rights
* Copyright (c) 2001-2004 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -88,7 +88,7 @@ import org.apache.commons.collections.map.AbstractSortedMapDecorator;
* not store each object twice, which can save on memory use.
*
* @since Commons Collections 3.0
* @version $Id: DualTreeBidiMap.java,v 1.7 2003/12/29 00:38:08 scolebourne Exp $
* @version $Id: DualTreeBidiMap.java,v 1.8 2004/01/02 01:36:51 psteitz Exp $
*
* @author Matthew Hawthorne
* @author Stephen Colebourne
@ -123,7 +123,7 @@ public class DualTreeBidiMap extends AbstractDualBidiMap implements SortedBidiMa
/**
* Constructs a <code>DualTreeBidiMap</code> using the specified Comparator.
*
* @param map the map whose mappings are to be placed in this map
* @param comparator the Comparator
*/
public DualTreeBidiMap(Comparator comparator) {
super();
@ -156,7 +156,7 @@ public class DualTreeBidiMap extends AbstractDualBidiMap implements SortedBidiMa
*
* @param normalMap the normal direction map
* @param reverseMap the reverse direction map
* @param inverseBidiMap the inverse BidiMap
* @param inverseMap the inverse BidiMap
* @return new bidi map
*/
protected BidiMap createBidiMap(Map normalMap, Map reverseMap, BidiMap inverseMap) {

View File

@ -1,10 +1,10 @@
/*
* $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 $
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/bidimap/TreeBidiMap.java,v 1.7 2004/01/02 01:36:51 psteitz Exp $
* ====================================================================
*
* The Apache Software License, Version 1.1
*
* Copyright (c) 2001-2003 The Apache Software Foundation. All rights
* Copyright (c) 2001-2004 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -108,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.6 $ $Date: 2003/12/06 13:03:15 $
* @version $Revision: 1.7 $ $Date: 2004/01/02 01:36:51 $
*
* @author Marc Johnson
* @author Stephen Colebourne
@ -333,7 +333,7 @@ public class TreeBidiMap implements OrderedBidiMap {
/**
* Gets the next key after the one specified.
*
* @param the key to search for next from
* @param key the key to search for next from
* @return the next key, null if no match or at end
*/
public Object nextKey(Object key) {
@ -345,7 +345,7 @@ public class TreeBidiMap implements OrderedBidiMap {
/**
* Gets the previous key before the one specified.
*
* @param the key to search for previous from
* @param key the key to search for previous from
* @return the previous key, null if no match or at start
*/
public Object previousKey(Object key) {
@ -473,7 +473,6 @@ public class TreeBidiMap implements OrderedBidiMap {
* Compares for equals as per the API.
*
* @param obj the object to compare to
* @param index the KEY or VALUE int
* @return true if equal
*/
public boolean equals(Object obj) {

View File

@ -1,5 +1,5 @@
/*
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/buffer/Attic/BinaryBuffer.java,v 1.2 2004/01/01 23:56:51 psteitz Exp $
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/buffer/Attic/BinaryBuffer.java,v 1.3 2004/01/02 01:36:51 psteitz Exp $
* ====================================================================
*
* The Apache Software License, Version 1.1
@ -92,7 +92,7 @@ import org.apache.commons.collections.BufferUnderflowException;
* </pre>
*
* @since Commons Collections 3.0 (previously BinaryHeap v1.0)
* @version $Revision: 1.2 $ $Date: 2004/01/01 23:56:51 $
* @version $Revision: 1.3 $ $Date: 2004/01/02 01:36:51 $
*
* @author Peter Donald
* @author Ram Chidambaram
@ -439,7 +439,7 @@ public class BinaryBuffer extends AbstractCollection implements Buffer {
* <p>
* Assume it is a maximum heap.
*
* @param element the element
* @param index the index of the element to be percolated up
*/
protected void percolateUpMaxHeap(final int index) {
int hole = index;

View File

@ -1,10 +1,10 @@
/*
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/functors/ChainedTransformer.java,v 1.1 2003/11/23 23:25:33 scolebourne Exp $
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/functors/ChainedTransformer.java,v 1.2 2004/01/02 01:36:51 psteitz Exp $
* ====================================================================
*
* The Apache Software License, Version 1.1
*
* Copyright (c) 2001-2003 The Apache Software Foundation. All rights
* Copyright (c) 2001-2004 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -67,7 +67,7 @@ import org.apache.commons.collections.Transformer;
* Transformer implementation that chains the specifed closures together.
*
* @since Commons Collections 3.0
* @version $Revision: 1.1 $ $Date: 2003/11/23 23:25:33 $
* @version $Revision: 1.2 $ $Date: 2004/01/02 01:36:51 $
*
* @author Stephen Colebourne
*/
@ -153,7 +153,7 @@ public class ChainedTransformer implements Transformer, Serializable {
/**
* Execute a list of transformers.
*
* @param input the input object passed to each transformer
* @param object the input object passed to each transformer
*/
public Object transform(Object object) {
for (int i = 0; i < iTransformers.length; i++) {

View File

@ -1,10 +1,10 @@
/*
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/functors/IfClosure.java,v 1.1 2003/11/23 17:01:35 scolebourne Exp $
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/functors/IfClosure.java,v 1.2 2004/01/02 01:36:51 psteitz Exp $
* ====================================================================
*
* The Apache Software License, Version 1.1
*
* Copyright (c) 2001-2003 The Apache Software Foundation. All rights
* Copyright (c) 2001-2004 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -67,7 +67,7 @@ import org.apache.commons.collections.Predicate;
* based on a predicate.
*
* @since Commons Collections 3.0
* @version $Revision: 1.1 $ $Date: 2003/11/23 17:01:35 $
* @version $Revision: 1.2 $ $Date: 2004/01/02 01:36:51 $
*
* @author Stephen Colebourne
*/
@ -86,12 +86,11 @@ public class IfClosure implements Closure, Serializable {
/**
* Factory method that performs validation.
*
* @param predicates array of predicates, cloned, no nulls
* @param closures matching array of closures, cloned, no nulls
* @param defaultClosure the closure to use if no match, null means nop
* @return the <code>chained</code> closure
* @throws IllegalArgumentException if array is null
* @throws IllegalArgumentException if any element in the array is null
* @param predicate predicate to switch on
* @param trueClosure closure used if true
* @param falseClosure closure used if false
* @return the <code>if</code> closure
* @throws IllegalArgumentException if any argument is null
*/
public static Closure getInstance(Predicate predicate, Closure trueClosure, Closure falseClosure) {
if (predicate == null) {

View File

@ -1,10 +1,10 @@
/*
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/functors/InstanceofPredicate.java,v 1.1 2003/11/23 19:11:21 scolebourne Exp $
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/functors/InstanceofPredicate.java,v 1.2 2004/01/02 01:36:51 psteitz Exp $
* ====================================================================
*
* The Apache Software License, Version 1.1
*
* Copyright (c) 2001-2003 The Apache Software Foundation. All rights
* Copyright (c) 2001-2004 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -66,7 +66,7 @@ import org.apache.commons.collections.Predicate;
* the type stored in this predicate.
*
* @since Commons Collections 3.0
* @version $Revision: 1.1 $ $Date: 2003/11/23 19:11:21 $
* @version $Revision: 1.2 $ $Date: 2004/01/02 01:36:51 $
*
* @author Stephen Colebourne
*/
@ -96,7 +96,7 @@ public final class InstanceofPredicate implements Predicate, Serializable {
* Constructor that performs no validation.
* Use <code>getInstance</code> if you want that.
*
* @param object the object to compare to
* @param type the type to check for
*/
public InstanceofPredicate(Class type) {
super();

View File

@ -1,10 +1,10 @@
/*
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/functors/MapTransformer.java,v 1.2 2003/11/27 23:57:09 scolebourne Exp $
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/functors/MapTransformer.java,v 1.3 2004/01/02 01:36:51 psteitz Exp $
* ====================================================================
*
* The Apache Software License, Version 1.1
*
* Copyright (c) 2001-2003 The Apache Software Foundation. All rights
* Copyright (c) 2001-2004 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -67,7 +67,7 @@ import org.apache.commons.collections.Transformer;
* using the input parameter as a key.
*
* @since Commons Collections 3.0
* @version $Revision: 1.2 $ $Date: 2003/11/27 23:57:09 $
* @version $Revision: 1.3 $ $Date: 2004/01/02 01:36:51 $
*
* @author Stephen Colebourne
*/
@ -84,7 +84,7 @@ public final class MapTransformer implements Transformer, Serializable {
* <p>
* If the map is null, a transformer that always returns null is returned.
*
* @param the map, not cloned
* @param map the map, not cloned
* @return the transformer
*/
public static Transformer getInstance(Map map) {

View File

@ -1,10 +1,10 @@
/*
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/list/NodeCachingLinkedList.java,v 1.3 2003/12/29 01:04:44 scolebourne Exp $
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/list/NodeCachingLinkedList.java,v 1.4 2004/01/02 01:36:52 psteitz Exp $
* ====================================================================
*
* The Apache Software License, Version 1.1
*
* Copyright (c) 2001-2003 The Apache Software Foundation. All rights
* Copyright (c) 2001-2004 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -78,7 +78,7 @@ import java.util.Collection;
* <b>Note that this implementation is not synchronized.</b>
*
* @since Commons Collections 3.0
* @version $Revision: 1.3 $ $Date: 2003/12/29 01:04:44 $
* @version $Revision: 1.4 $ $Date: 2004/01/02 01:36:52 $
*
* @author Jeff Varszegi
* @author Rich Dougherty
@ -252,7 +252,6 @@ public class NodeCachingLinkedList extends AbstractLinkedList implements Seriali
* Removes all the nodes from the list, storing as many as required in the
* cache for reuse.
*
* @param node the node to remove
*/
protected void removeAllNodes() {
// Add the removed nodes to the cache, then remove the rest.

View File

@ -1,10 +1,10 @@
/*
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/map/AbstractHashedMap.java,v 1.4 2003/12/29 00:38:08 scolebourne Exp $
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/map/AbstractHashedMap.java,v 1.5 2004/01/02 01:36:52 psteitz Exp $
* ====================================================================
*
* The Apache Software License, Version 1.1
*
* Copyright (c) 2001-2003 The Apache Software Foundation. All rights
* Copyright (c) 2001-2004 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -88,7 +88,7 @@ import org.apache.commons.collections.MapIterator;
* need for unusual subclasses is here.
*
* @since Commons Collections 3.0
* @version $Revision: 1.4 $ $Date: 2003/12/29 00:38:08 $
* @version $Revision: 1.5 $ $Date: 2004/01/02 01:36:52 $
*
* @author java util HashMap
* @author Stephen Colebourne
@ -550,12 +550,9 @@ public class AbstractHashedMap implements IterableMap {
* <p>
* This implementation adds the entry to the data storage table.
* Subclasses could override to handle changes to the map.
*
*
* @param entry the entry to add
* @param hashIndex the index into the data array to store at
* @param hashCode the hash code of the key to add
* @param key the key to add
* @param value the value to add
* @return the value previously mapped to this key, null if none
*/
protected void addEntry(HashEntry entry, int hashIndex) {
data[hashIndex] = entry;

View File

@ -1,10 +1,10 @@
/*
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/map/LRUMap.java,v 1.4 2003/12/11 22:55:25 scolebourne Exp $
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/map/LRUMap.java,v 1.5 2004/01/02 01:36:52 psteitz Exp $
* ====================================================================
*
* The Apache Software License, Version 1.1
*
* Copyright (c) 2001-2003 The Apache Software Foundation. All rights
* Copyright (c) 2001-2004 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -83,7 +83,7 @@ import org.apache.commons.collections.BoundedMap;
* <code>ResettableIterator</code> and calling <code>reset()</code>.
*
* @since Commons Collections 3.0
* @version $Revision: 1.4 $ $Date: 2003/12/11 22:55:25 $
* @version $Revision: 1.5 $ $Date: 2004/01/02 01:36:52 $
*
* @author James Strachan
* @author Morgan Delagrange
@ -173,8 +173,6 @@ public class LRUMap extends AbstractLinkedMap
* This implementation moves the updated entry to the end of the list.
*
* @param entry the entry to update
* @param newValue the new value to store
* @return value the previous value
*/
protected void moveToMRU(LinkEntry entry) {
if (entry.after != header) {