Work around a problem reported by the VAJ Java compiler, caused by the

fact that the superclass already has a private class named Iterator.

Submitted by:	Costin Cozianu <Costin.Cozianu@cis.canon.com>


git-svn-id: https://svn.apache.org/repos/asf/jakarta/commons/proper/collections/trunk@130485 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Craig R. McClanahan 2001-05-20 21:03:30 +00:00
parent 3761b55144
commit a36442f0d0
3 changed files with 22 additions and 22 deletions

View File

@ -1,7 +1,7 @@
/* /*
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/FastArrayList.java,v 1.2 2001/04/21 12:19:57 craigmcc Exp $ * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/FastArrayList.java,v 1.3 2001/05/20 21:03:30 craigmcc Exp $
* $Revision: 1.2 $ * $Revision: 1.3 $
* $Date: 2001/04/21 12:19:57 $ * $Date: 2001/05/20 21:03:30 $
* *
* ==================================================================== * ====================================================================
* *
@ -94,7 +94,7 @@ import java.util.ListIterator;
* maximum performance.</p> * maximum performance.</p>
* *
* @author Craig R. McClanahan * @author Craig R. McClanahan
* @version $Revision: 1.2 $ $Date: 2001/04/21 12:19:57 $ * @version $Revision: 1.3 $ $Date: 2001/05/20 21:03:30 $
*/ */
public class FastArrayList extends ArrayList { public class FastArrayList extends ArrayList {
@ -452,7 +452,7 @@ public class FastArrayList extends ArrayList {
if (fast) { if (fast) {
int hashCode = 1; int hashCode = 1;
Iterator i = list.iterator(); java.util.Iterator i = list.iterator();
while (i.hasNext()) { while (i.hasNext()) {
Object o = i.next(); Object o = i.next();
hashCode = 31 * hashCode + (o == null ? 0 : o.hashCode()); hashCode = 31 * hashCode + (o == null ? 0 : o.hashCode());
@ -461,7 +461,7 @@ public class FastArrayList extends ArrayList {
} else { } else {
synchronized (list) { synchronized (list) {
int hashCode = 1; int hashCode = 1;
Iterator i = list.iterator(); java.util.Iterator i = list.iterator();
while (i.hasNext()) { while (i.hasNext()) {
Object o = i.next(); Object o = i.next();
hashCode = 31 * hashCode + (o == null ? 0 : o.hashCode()); hashCode = 31 * hashCode + (o == null ? 0 : o.hashCode());

View File

@ -1,7 +1,7 @@
/* /*
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/FastHashMap.java,v 1.3 2001/05/18 00:12:45 rwaldhoff Exp $ * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/FastHashMap.java,v 1.4 2001/05/20 21:03:30 craigmcc Exp $
* $Revision: 1.3 $ * $Revision: 1.4 $
* $Date: 2001/05/18 00:12:45 $ * $Date: 2001/05/20 21:03:30 $
* *
* ==================================================================== * ====================================================================
* *
@ -95,7 +95,7 @@ import java.util.Set;
* maximum performance.</p> * maximum performance.</p>
* *
* @author Craig R. McClanahan * @author Craig R. McClanahan
* @version $Revision: 1.3 $ $Date: 2001/05/18 00:12:45 $ * @version $Revision: 1.4 $ $Date: 2001/05/20 21:03:30 $
*/ */
public class FastHashMap extends HashMap { public class FastHashMap extends HashMap {
@ -300,7 +300,7 @@ public class FastHashMap extends HashMap {
if (fast) { if (fast) {
if (mo.size() != map.size()) if (mo.size() != map.size())
return (false); return (false);
Iterator i = map.entrySet().iterator(); java.util.Iterator i = map.entrySet().iterator();
while (i.hasNext()) { while (i.hasNext()) {
Map.Entry e = (Map.Entry) i.next(); Map.Entry e = (Map.Entry) i.next();
Object key = e.getKey(); Object key = e.getKey();
@ -318,7 +318,7 @@ public class FastHashMap extends HashMap {
synchronized (map) { synchronized (map) {
if (mo.size() != map.size()) if (mo.size() != map.size())
return (false); return (false);
Iterator i = map.entrySet().iterator(); java.util.Iterator i = map.entrySet().iterator();
while (i.hasNext()) { while (i.hasNext()) {
Map.Entry e = (Map.Entry) i.next(); Map.Entry e = (Map.Entry) i.next();
Object key = e.getKey(); Object key = e.getKey();
@ -368,14 +368,14 @@ public class FastHashMap extends HashMap {
if (fast) { if (fast) {
int h = 0; int h = 0;
Iterator i = map.entrySet().iterator(); java.util.Iterator i = map.entrySet().iterator();
while (i.hasNext()) while (i.hasNext())
h += i.next().hashCode(); h += i.next().hashCode();
return (h); return (h);
} else { } else {
synchronized (map) { synchronized (map) {
int h = 0; int h = 0;
Iterator i = map.entrySet().iterator(); java.util.Iterator i = map.entrySet().iterator();
while (i.hasNext()) while (i.hasNext())
h += i.next().hashCode(); h += i.next().hashCode();
return (h); return (h);

View File

@ -1,7 +1,7 @@
/* /*
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/FastTreeMap.java,v 1.3 2001/05/18 00:12:45 rwaldhoff Exp $ * $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/FastTreeMap.java,v 1.4 2001/05/20 21:03:30 craigmcc Exp $
* $Revision: 1.3 $ * $Revision: 1.4 $
* $Date: 2001/05/18 00:12:45 $ * $Date: 2001/05/20 21:03:30 $
* *
* ==================================================================== * ====================================================================
* *
@ -97,7 +97,7 @@ import java.util.TreeMap;
* maximum performance.</p> * maximum performance.</p>
* *
* @author Craig R. McClanahan * @author Craig R. McClanahan
* @version $Revision: 1.3 $ $Date: 2001/05/18 00:12:45 $ * @version $Revision: 1.4 $ $Date: 2001/05/20 21:03:30 $
*/ */
public class FastTreeMap extends TreeMap { public class FastTreeMap extends TreeMap {
@ -320,7 +320,7 @@ public class FastTreeMap extends TreeMap {
if (fast) { if (fast) {
if (mo.size() != map.size()) if (mo.size() != map.size())
return (false); return (false);
Iterator i = map.entrySet().iterator(); java.util.Iterator i = map.entrySet().iterator();
while (i.hasNext()) { while (i.hasNext()) {
Map.Entry e = (Map.Entry) i.next(); Map.Entry e = (Map.Entry) i.next();
Object key = e.getKey(); Object key = e.getKey();
@ -338,7 +338,7 @@ public class FastTreeMap extends TreeMap {
synchronized (map) { synchronized (map) {
if (mo.size() != map.size()) if (mo.size() != map.size())
return (false); return (false);
Iterator i = map.entrySet().iterator(); java.util.Iterator i = map.entrySet().iterator();
while (i.hasNext()) { while (i.hasNext()) {
Map.Entry e = (Map.Entry) i.next(); Map.Entry e = (Map.Entry) i.next();
Object key = e.getKey(); Object key = e.getKey();
@ -404,14 +404,14 @@ public class FastTreeMap extends TreeMap {
if (fast) { if (fast) {
int h = 0; int h = 0;
Iterator i = map.entrySet().iterator(); java.util.Iterator i = map.entrySet().iterator();
while (i.hasNext()) while (i.hasNext())
h += i.next().hashCode(); h += i.next().hashCode();
return (h); return (h);
} else { } else {
synchronized (map) { synchronized (map) {
int h = 0; int h = 0;
Iterator i = map.entrySet().iterator(); java.util.Iterator i = map.entrySet().iterator();
while (i.hasNext()) while (i.hasNext())
h += i.next().hashCode(); h += i.next().hashCode();
return (h); return (h);