1 |
/* Hashtable.java -- a class providing a basic hashtable data structure, |
/* Hashtable.java -- a class providing a basic hashtable data structure, |
2 |
mapping Object --> Object |
mapping Object --> Object |
3 |
Copyright (C) 1998, 1999, 2000, 2001 Free Software Foundation, Inc. |
Copyright (C) 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc. |
4 |
|
|
5 |
This file is part of GNU Classpath. |
This file is part of GNU Classpath. |
6 |
|
|
176 |
* pair. A Hashtable Entry is identical to a HashMap Entry, except that |
* pair. A Hashtable Entry is identical to a HashMap Entry, except that |
177 |
* `null' is not allowed for keys and values. |
* `null' is not allowed for keys and values. |
178 |
*/ |
*/ |
179 |
private static final class HashEntry extends BasicMapEntry |
private static final class HashEntry extends AbstractMap.BasicMapEntry |
180 |
{ |
{ |
181 |
/** The next entry in the linked list. */ |
/** The next entry in the linked list. */ |
182 |
HashEntry next; |
HashEntry next; |
517 |
{ |
{ |
518 |
Map.Entry e = (Map.Entry) itr.next(); |
Map.Entry e = (Map.Entry) itr.next(); |
519 |
// Optimize in case the Entry is one of our own. |
// Optimize in case the Entry is one of our own. |
520 |
if (e instanceof BasicMapEntry) |
if (e instanceof AbstractMap.BasicMapEntry) |
521 |
{ |
{ |
522 |
BasicMapEntry entry = (BasicMapEntry) e; |
AbstractMap.BasicMapEntry entry = (AbstractMap.BasicMapEntry) e; |
523 |
put(entry.key, entry.value); |
put(entry.key, entry.value); |
524 |
} |
} |
525 |
else |
else |