|
From: <ls...@us...> - 2007-08-11 19:58:16
|
Revision: 3392
http://jnode.svn.sourceforge.net/jnode/?rev=3392&view=rev
Author: lsantha
Date: 2007-08-11 12:58:14 -0700 (Sat, 11 Aug 2007)
Log Message:
-----------
Openjdk integration.
Removed Paths:
-------------
trunk/core/src/classpath/java/java/util/Collection.java
trunk/core/src/classpath/java/java/util/Comparator.java
trunk/core/src/classpath/java/java/util/ConcurrentModificationException.java
trunk/core/src/classpath/java/java/util/Deque.java
trunk/core/src/classpath/java/java/util/DuplicateFormatFlagsException.java
trunk/core/src/classpath/java/java/util/EmptyStackException.java
trunk/core/src/classpath/java/java/util/Enumeration.java
trunk/core/src/classpath/java/java/util/Iterator.java
trunk/core/src/classpath/java/java/util/List.java
trunk/core/src/classpath/java/java/util/Map.java
trunk/core/src/classpath/java/java/util/Queue.java
trunk/core/src/classpath/java/java/util/RandomAccess.java
trunk/core/src/classpath/java/java/util/Set.java
trunk/core/src/classpath/java/java/util/SortedMap.java
trunk/core/src/classpath/java/java/util/SortedSet.java
trunk/core/src/classpath/java/java/util/package.html
Deleted: trunk/core/src/classpath/java/java/util/Collection.java
===================================================================
--- trunk/core/src/classpath/java/java/util/Collection.java 2007-08-11 19:55:49 UTC (rev 3391)
+++ trunk/core/src/classpath/java/java/util/Collection.java 2007-08-11 19:58:14 UTC (rev 3392)
@@ -1,290 +0,0 @@
-/* Collection.java -- Interface that represents a collection of objects
- Copyright (C) 1998, 2001, 2004, 2005 Free Software Foundation, Inc.
-
-This file is part of GNU Classpath.
-
-GNU Classpath is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-GNU Classpath is distributed in the hope that it will be useful, but
-WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with GNU Classpath; see the file COPYING. If not, write to the
-Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
-02110-1301 USA.
-
-Linking this library statically or dynamically with other modules is
-making a combined work based on this library. Thus, the terms and
-conditions of the GNU General Public License cover the whole
-combination.
-
-As a special exception, the copyright holders of this library give you
-permission to link this library with independent modules to produce an
-executable, regardless of the license terms of these independent
-modules, and to copy and distribute the resulting executable under
-terms of your choice, provided that you also meet, for each linked
-independent module, the terms and conditions of the license of that
-module. An independent module is a module which is not derived from
-or based on this library. If you modify this library, you may extend
-this exception to your version of the library, but you are not
-obligated to do so. If you do not wish to do so, delete this
-exception statement from your version. */
-
-
-package java.util;
-
-/**
- * Interface that represents a collection of objects. This interface is the
- * root of the collection hierarchy, and does not provide any guarantees about
- * the order of its elements or whether or not duplicate elements are
- * permitted.
- * <p>
- * All methods of this interface that are defined to modify the collection are
- * defined as <dfn>optional</dfn>. An optional operation may throw an
- * UnsupportedOperationException if the data backing this collection does not
- * support such a modification. This may mean that the data structure is
- * immutable, or that it is read-only but may change ("unmodifiable"), or
- * that it is modifiable but of fixed size (such as an array), or any number
- * of other combinations.
- * <p>
- * A class that wishes to implement this interface should consider subclassing
- * AbstractCollection, which provides basic implementations of most of the
- * methods of this interface. Classes that are prepared to make guarantees
- * about ordering or about absence of duplicate elements should consider
- * implementing List or Set respectively, both of which are subinterfaces of
- * Collection.
- * <p>
- * A general-purpose implementation of the Collection interface should in most
- * cases provide at least two constructors: One which takes no arguments and
- * creates an empty collection, and one which takes a Collection as an argument
- * and returns a collection containing the same elements (that is, creates a
- * copy of the argument using its own implementation).
- *
- * @author Original author unknown
- * @author Eric Blake (eb...@em...)
- * @author Tom Tromey (tr...@re...)
- * @author Andrew John Hughes (gnu...@me...)
- * @see List
- * @see Set
- * @see Map
- * @see SortedSet
- * @see SortedMap
- * @see HashSet
- * @see TreeSet
- * @see ArrayList
- * @see LinkedList
- * @see Vector
- * @see Collections
- * @see Arrays
- * @see AbstractCollection
- * @since 1.2
- * @status updated to 1.4
- */
-public interface Collection<E> extends Iterable<E>
-{
- /**
- * Add an element to this collection.
- *
- * @param o the object to add.
- * @return true if the collection was modified as a result of this action.
- * @throws UnsupportedOperationException if this collection does not
- * support the add operation.
- * @throws ClassCastException if o cannot be added to this collection due
- * to its type.
- * @throws NullPointerException if o is null and this collection doesn't
- * support the addition of null values.
- * @throws IllegalArgumentException if o cannot be added to this
- * collection for some other reason.
- */
- boolean add(E o);
-
- /**
- * Add the contents of a given collection to this collection.
- *
- * @param c the collection to add.
- * @return true if the collection was modified as a result of this action.
- * @throws UnsupportedOperationException if this collection does not
- * support the addAll operation.
- * @throws ClassCastException if some element of c cannot be added to this
- * collection due to its type.
- * @throws NullPointerException if some element of c is null and this
- * collection does not support the addition of null values.
- * @throws NullPointerException if c itself is null.
- * @throws IllegalArgumentException if some element of c cannot be added
- * to this collection for some other reason.
- */
- boolean addAll(Collection<? extends E> c);
-
- /**
- * Clear the collection, such that a subsequent call to isEmpty() would
- * return true.
- *
- * @throws UnsupportedOperationException if this collection does not
- * support the clear operation.
- */
- void clear();
-
- /**
- * Test whether this collection contains a given object as one of its
- * elements.
- *
- * @param o the element to look for.
- * @return true if this collection contains at least one element e such that
- * <code>o == null ? e == null : o.equals(e)</code>.
- * @throws ClassCastException if the type of o is not a valid type for this
- * collection.
- * @throws NullPointerException if o is null and this collection doesn't
- * support null values.
- */
- boolean contains(Object o);
-
- /**
- * Test whether this collection contains every element in a given collection.
- *
- * @param c the collection to test for.
- * @return true if for every element o in c, contains(o) would return true.
- * @throws ClassCastException if the type of any element in c is not a valid
- * type for this collection.
- * @throws NullPointerException if some element of c is null and this
- * collection does not support null values.
- * @throws NullPointerException if c itself is null.
- */
- boolean containsAll(Collection<?> c);
-
- /**
- * Test whether this collection is equal to some object. The Collection
- * interface does not explicitly require any behaviour from this method, and
- * it may be left to the default implementation provided by Object. The Set
- * and List interfaces do, however, require specific behaviour from this
- * method.
- * <p>
- * If an implementation of Collection, which is not also an implementation of
- * Set or List, should choose to implement this method, it should take care
- * to obey the contract of the equals method of Object. In particular, care
- * should be taken to return false when o is a Set or a List, in order to
- * preserve the symmetry of the relation.
- *
- * @param o the object to compare to this collection.
- * @return true if the o is equal to this collection.
- */
- boolean equals(Object o);
-
- /**
- * Obtain a hash code for this collection. The Collection interface does not
- * explicitly require any behaviour from this method, and it may be left to
- * the default implementation provided by Object. The Set and List interfaces
- * do, however, require specific behaviour from this method.
- * <p>
- * If an implementation of Collection, which is not also an implementation of
- * Set or List, should choose to implement this method, it should take care
- * to obey the contract of the hashCode method of Object. Note that this
- * method renders it impossible to correctly implement both Set and List, as
- * the required implementations are mutually exclusive.
- *
- * @return a hash code for this collection.
- */
- int hashCode();
-
- /**
- * Test whether this collection is empty, that is, if size() == 0.
- *
- * @return true if this collection contains no elements.
- */
- boolean isEmpty();
-
- /**
- * Obtain an Iterator over this collection.
- *
- * @return an Iterator over the elements of this collection, in any order.
- */
- Iterator<E> iterator();
-
- /**
- * Remove a single occurrence of an object from this collection. That is,
- * remove an element e, if one exists, such that <code>o == null ? e == null
- * : o.equals(e)</code>.
- *
- * @param o the object to remove.
- * @return true if the collection changed as a result of this call, that is,
- * if the collection contained at least one occurrence of o.
- * @throws UnsupportedOperationException if this collection does not
- * support the remove operation.
- * @throws ClassCastException if the type of o is not a valid type
- * for this collection.
- * @throws NullPointerException if o is null and the collection doesn't
- * support null values.
- */
- boolean remove(Object o);
-
- /**
- * Remove all elements of a given collection from this collection. That is,
- * remove every element e such that c.contains(e).
- *
- * @param c The collection of objects to be removed.
- * @return true if this collection was modified as a result of this call.
- * @throws UnsupportedOperationException if this collection does not
- * support the removeAll operation.
- * @throws ClassCastException if the type of any element in c is not a valid
- * type for this collection.
- * @throws NullPointerException if some element of c is null and this
- * collection does not support removing null values.
- * @throws NullPointerException if c itself is null.
- */
- boolean removeAll(Collection<?> c);
-
- /**
- * Remove all elements of this collection that are not contained in a given
- * collection. That is, remove every element e such that !c.contains(e).
- *
- * @param c The collection of objects to be retained.
- * @return true if this collection was modified as a result of this call.
- * @throws UnsupportedOperationException if this collection does not
- * support the retainAll operation.
- * @throws ClassCastException if the type of any element in c is not a valid
- * type for this collection.
- * @throws NullPointerException if some element of c is null and this
- * collection does not support retaining null values.
- * @throws NullPointerException if c itself is null.
- */
- boolean retainAll(Collection<?> c);
-
- /**
- * Get the number of elements in this collection.
- *
- * @return the number of elements in the collection.
- */
- int size();
-
- /**
- * Copy the current contents of this collection into an array.
- *
- * @return an array of type Object[] and length equal to the size of this
- * collection, containing the elements currently in this collection, in
- * any order.
- */
- Object[] toArray();
-
- /**
- * Copy the current contents of this collection into an array. If the array
- * passed as an argument has length less than the size of this collection, an
- * array of the same run-time type as a, and length equal to the size of this
- * collection, is allocated using Reflection. Otherwise, a itself is used.
- * The elements of this collection are copied into it, and if there is space
- * in the array, the following element is set to null. The resultant array is
- * returned.
- * Note: The fact that the following element is set to null is only useful
- * if it is known that this collection does not contain any null elements.
- *
- * @param a the array to copy this collection into.
- * @return an array containing the elements currently in this collection, in
- * any order.
- * @throws ArrayStoreException if the type of any element of the
- * collection is not a subtype of the element type of a.
- */
- <T> T[] toArray(T[] a);
-}
Deleted: trunk/core/src/classpath/java/java/util/Comparator.java
===================================================================
--- trunk/core/src/classpath/java/java/util/Comparator.java 2007-08-11 19:55:49 UTC (rev 3391)
+++ trunk/core/src/classpath/java/java/util/Comparator.java 2007-08-11 19:58:14 UTC (rev 3392)
@@ -1,119 +0,0 @@
-/* Comparator.java -- Interface for objects that specify an ordering
- Copyright (C) 1998, 2001, 2004, 2005 Free Software Foundation, Inc.
-
-This file is part of GNU Classpath.
-
-GNU Classpath is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-GNU Classpath is distributed in the hope that it will be useful, but
-WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with GNU Classpath; see the file COPYING. If not, write to the
-Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
-02110-1301 USA.
-
-Linking this library statically or dynamically with other modules is
-making a combined work based on this library. Thus, the terms and
-conditions of the GNU General Public License cover the whole
-combination.
-
-As a special exception, the copyright holders of this library give you
-permission to link this library with independent modules to produce an
-executable, regardless of the license terms of these independent
-modules, and to copy and distribute the resulting executable under
-terms of your choice, provided that you also meet, for each linked
-independent module, the terms and conditions of the license of that
-module. An independent module is a module which is not derived from
-or based on this library. If you modify this library, you may extend
-this exception to your version of the library, but you are not
-obligated to do so. If you do not wish to do so, delete this
-exception statement from your version. */
-
-
-package java.util;
-
-/**
- * Interface for objects that specify an ordering between objects. The ordering
- * should be <em>total</em>, such that any two objects of the correct type
- * can be compared, and the comparison is reflexive, anti-symmetric, and
- * transitive. It is also recommended that the comparator be <em>consistent
- * with equals</em>, although this is not a strict requirement. A relation
- * is consistent with equals if these two statements always have the same
- * results (if no exceptions occur):<br>
- * <code>compare((Object) e1, (Object) e2) == 0</code> and
- * <code>e1.equals((Object) e2)</code><br>
- * Comparators that violate consistency with equals may cause strange behavior
- * in sorted lists and sets. For example, a case-sensitive dictionary order
- * comparison of Strings is consistent with equals, but if it is
- * case-insensitive it is not, because "abc" and "ABC" compare as equal even
- * though "abc".equals("ABC") returns false.
- * <P>
- * In general, Comparators should be Serializable, because when they are passed
- * to Serializable data structures such as SortedMap or SortedSet, the entire
- * data structure will only serialize correctly if the comparator is
- * Serializable.
- *
- * @author Original author unknown
- * @author Eric Blake (eb...@em...)
- * @see Comparable
- * @see TreeMap
- * @see TreeSet
- * @see SortedMap
- * @see SortedSet
- * @see Arrays#sort(Object[], Comparator)
- * @see java.io.Serializable
- * @since 1.2
- * @status updated to 1.4
- */
-public interface Comparator<T>
-{
- /**
- * Return an integer that is negative, zero or positive depending on whether
- * the first argument is less than, equal to or greater than the second
- * according to this ordering. This method should obey the following
- * contract:
- * <ul>
- * <li>if compare(a, b) < 0 then compare(b, a) > 0</li>
- * <li>if compare(a, b) throws an exception, so does compare(b, a)</li>
- * <li>if compare(a, b) < 0 and compare(b, c) < 0 then compare(a, c)
- * < 0</li>
- * <li>if compare(a, b) == 0 then compare(a, c) and compare(b, c) must
- * have the same sign</li>
- * </ul>
- * To be consistent with equals, the following additional constraint is
- * in place:
- * <ul>
- * <li>if a.equals(b) or both a and b are null, then
- * compare(a, b) == 0.</li>
- * </ul><p>
- *
- * Although it is permissible for a comparator to provide an order
- * inconsistent with equals, that should be documented.
- *
- * @param o1 the first object
- * @param o2 the second object
- * @return the comparison
- * @throws ClassCastException if the elements are not of types that can be
- * compared by this ordering.
- */
- int compare(T o1, T o2);
-
- /**
- * Return true if the object is equal to this object. To be
- * considered equal, the argument object must satisfy the constraints
- * of <code>Object.equals()</code>, be a Comparator, and impose the
- * same ordering as this Comparator. The default implementation
- * inherited from Object is usually adequate.
- *
- * @param obj The object
- * @return true if it is a Comparator that imposes the same order
- * @see Object#equals(Object)
- */
- boolean equals(Object obj);
-}
Deleted: trunk/core/src/classpath/java/java/util/ConcurrentModificationException.java
===================================================================
--- trunk/core/src/classpath/java/java/util/ConcurrentModificationException.java 2007-08-11 19:55:49 UTC (rev 3391)
+++ trunk/core/src/classpath/java/java/util/ConcurrentModificationException.java 2007-08-11 19:58:14 UTC (rev 3392)
@@ -1,92 +0,0 @@
-/* ConcurrentModificationException.java -- Data structure concurrently modified
- Copyright (C) 1998, 1999, 2001, 2005 Free Software Foundation, Inc.
-
-This file is part of GNU Classpath.
-
-GNU Classpath is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-GNU Classpath is distributed in the hope that it will be useful, but
-WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with GNU Classpath; see the file COPYING. If not, write to the
-Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
-02110-1301 USA.
-
-Linking this library statically or dynamically with other modules is
-making a combined work based on this library. Thus, the terms and
-conditions of the GNU General Public License cover the whole
-combination.
-
-As a special exception, the copyright holders of this library give you
-permission to link this library with independent modules to produce an
-executable, regardless of the license terms of these independent
-modules, and to copy and distribute the resulting executable under
-terms of your choice, provided that you also meet, for each linked
-independent module, the terms and conditions of the license of that
-module. An independent module is a module which is not derived from
-or based on this library. If you modify this library, you may extend
-this exception to your version of the library, but you are not
-obligated to do so. If you do not wish to do so, delete this
-exception statement from your version. */
-
-
-package java.util;
-
-/* Written using "Java Class Libraries", 2nd edition, ISBN 0-201-31002-3
- * "The Java Language Specification", ISBN 0-201-63451-1
- * plus online API docs for JDK 1.2 beta from http://www.javasoft.com.
- */
-
-/**
- * Exception that is thrown by the collections classes when it is detected that
- * a modification has been made to a data structure when this is not allowed,
- * such as when a collection is structurally modified while an Iterator is
- * operating over it. In cases where this can be detected, a
- * ConcurrentModificationException will be thrown. An Iterator that detects
- * this condition is referred to as fail-fast. Notice that this can occur
- * even in single-threaded designs, if you call methods out of order.
- *
- * @author Warren Levy (wa...@cy...)
- * @author Eric Blake (eb...@em...)
- * @see Collection
- * @see Iterator
- * @see ListIterator
- * @see Vector
- * @see LinkedList
- * @see HashSet
- * @see Hashtable
- * @see TreeMap
- * @see AbstractList
- * @since 1.2
- * @status updated to 1.4
- */
-public class ConcurrentModificationException extends RuntimeException
-{
- /**
- * Compatible with JDK 1.2.
- */
- private static final long serialVersionUID = -3666751008965953603L;
-
- /**
- * Constructs a ConcurrentModificationException with no detail message.
- */
- public ConcurrentModificationException()
- {
- }
-
- /**
- * Constructs a ConcurrentModificationException with a detail message.
- *
- * @param detail the detail message for the exception
- */
- public ConcurrentModificationException(String detail)
- {
- super(detail);
- }
-}
Deleted: trunk/core/src/classpath/java/java/util/Deque.java
===================================================================
--- trunk/core/src/classpath/java/java/util/Deque.java 2007-08-11 19:55:49 UTC (rev 3391)
+++ trunk/core/src/classpath/java/java/util/Deque.java 2007-08-11 19:58:14 UTC (rev 3392)
@@ -1,547 +0,0 @@
-/*
- * Written by Doug Lea and Josh Bloch with assistance from members of
- * JCP JSR-166 Expert Group and released to the public domain, as explained
- * at http://creativecommons.org/licenses/publicdomain
- */
-
-package java.util;
-
-/**
- * A linear collection that supports element insertion and removal at
- * both ends. The name <i>deque</i> is short for "double ended queue"
- * and is usually pronounced "deck". Most <tt>Deque</tt>
- * implementations place no fixed limits on the number of elements
- * they may contain, but this interface supports capacity-restricted
- * deques as well as those with no fixed size limit.
- *
- * <p>This interface defines methods to access the elements at both
- * ends of the deque. Methods are provided to insert, remove, and
- * examine the element. Each of these methods exists in two forms:
- * one throws an exception if the operation fails, the other returns a
- * special value (either <tt>null</tt> or <tt>false</tt>, depending on
- * the operation). The latter form of the insert operation is
- * designed specifically for use with capacity-restricted
- * <tt>Deque</tt> implementations; in most implementations, insert
- * operations cannot fail.
- *
- * <p>The twelve methods described above are summarized in the
- * following table:
- *
- * <p>
- * <table BORDER CELLPADDING=3 CELLSPACING=1>
- * <tr>
- * <td></td>
- * <td ALIGN=CENTER COLSPAN = 2> <b>First Element (Head)</b></td>
- * <td ALIGN=CENTER COLSPAN = 2> <b>Last Element (Tail)</b></td>
- * </tr>
- * <tr>
- * <td></td>
- * <td ALIGN=CENTER><em>Throws exception</em></td>
- * <td ALIGN=CENTER><em>Special value</em></td>
- * <td ALIGN=CENTER><em>Throws exception</em></td>
- * <td ALIGN=CENTER><em>Special value</em></td>
- * </tr>
- * <tr>
- * <td><b>Insert</b></td>
- * <td>{@link #addFirst addFirst(e)}</td>
- * <td>{@link #offerFirst offerFirst(e)}</td>
- * <td>{@link #addLast addLast(e)}</td>
- * <td>{@link #offerLast offerLast(e)}</td>
- * </tr>
- * <tr>
- * <td><b>Remove</b></td>
- * <td>{@link #removeFirst removeFirst()}</td>
- * <td>{@link #pollFirst pollFirst()}</td>
- * <td>{@link #removeLast removeLast()}</td>
- * <td>{@link #pollLast pollLast()}</td>
- * </tr>
- * <tr>
- * <td><b>Examine</b></td>
- * <td>{@link #getFirst getFirst()}</td>
- * <td>{@link #peekFirst peekFirst()}</td>
- * <td>{@link #getLast getLast()}</td>
- * <td>{@link #peekLast peekLast()}</td>
- * </tr>
- * </table>
- *
- * <p>This interface extends the {@link Queue} interface. When a deque is
- * used as a queue, FIFO (First-In-First-Out) behavior results. Elements are
- * added at the end of the deque and removed from the beginning. The methods
- * inherited from the <tt>Queue</tt> interface are precisely equivalent to
- * <tt>Deque</tt> methods as indicated in the following table:
- *
- * <p>
- * <table BORDER CELLPADDING=3 CELLSPACING=1>
- * <tr>
- * <td ALIGN=CENTER> <b><tt>Queue</tt> Method</b></td>
- * <td ALIGN=CENTER> <b>Equivalent <tt>Deque</tt> Method</b></td>
- * </tr>
- * <tr>
- * <td>{@link java.util.Queue#add add(e)}</td>
- * <td>{@link #addLast addLast(e)}</td>
- * </tr>
- * <tr>
- * <td>{@link java.util.Queue#offer offer(e)}</td>
- * <td>{@link #offerLast offerLast(e)}</td>
- * </tr>
- * <tr>
- * <td>{@link java.util.Queue#remove remove()}</td>
- * <td>{@link #removeFirst removeFirst()}</td>
- * </tr>
- * <tr>
- * <td>{@link java.util.Queue#poll poll()}</td>
- * <td>{@link #pollFirst pollFirst()}</td>
- * </tr>
- * <tr>
- * <td>{@link java.util.Queue#element element()}</td>
- * <td>{@link #getFirst getFirst()}</td>
- * </tr>
- * <tr>
- * <td>{@link java.util.Queue#peek peek()}</td>
- * <td>{@link #peek peekFirst()}</td>
- * </tr>
- * </table>
- *
- * <p>Deques can also be used as LIFO (Last-In-First-Out) stacks. This
- * interface should be used in preference to the legacy {@link Stack} class.
- * When a deque is used as a stack, elements are pushed and popped from the
- * beginning of the deque. Stack methods are precisely equivalent to
- * <tt>Deque</tt> methods as indicated in the table below:
- *
- * <p>
- * <table BORDER CELLPADDING=3 CELLSPACING=1>
- * <tr>
- * <td ALIGN=CENTER> <b>Stack Method</b></td>
- * <td ALIGN=CENTER> <b>Equivalent <tt>Deque</tt> Method</b></td>
- * </tr>
- * <tr>
- * <td>{@link #push push(e)}</td>
- * <td>{@link #addFirst addFirst(e)}</td>
- * </tr>
- * <tr>
- * <td>{@link #pop pop()}</td>
- * <td>{@link #removeFirst removeFirst()}</td>
- * </tr>
- * <tr>
- * <td>{@link #peek peek()}</td>
- * <td>{@link #peekFirst peekFirst()}</td>
- * </tr>
- * </table>
- *
- * <p>Note that the {@link #peek peek} method works equally well when
- * a deque is used as a queue or a stack; in either case, elements are
- * drawn from the beginning of the deque.
- *
- * <p>This interface provides two methods to remove interior
- * elements, {@link #removeFirstOccurrence removeFirstOccurrence} and
- * {@link #removeLastOccurrence removeLastOccurrence}.
- *
- * <p>Unlike the {@link List} interface, this interface does not
- * provide support for indexed access to elements.
- *
- * <p>While <tt>Deque</tt> implementations are not strictly required
- * to prohibit the insertion of null elements, they are strongly
- * encouraged to do so. Users of any <tt>Deque</tt> implementations
- * that do allow null elements are strongly encouraged <i>not</i> to
- * take advantage of the ability to insert nulls. This is so because
- * <tt>null</tt> is used as a special return value by various methods
- * to indicated that the deque is empty.
- *
- * <p><tt>Deque</tt> implementations generally do not define
- * element-based versions of the <tt>equals</tt> and <tt>hashCode</tt>
- * methods, but instead inherit the identity-based versions from class
- * <tt>Object</tt>.
- *
- * <p>This interface is a member of the <a
- * href="{@docRoot}/../technotes/guides/collections/index.html"> Java Collections
- * Framework</a>.
- *
- * @author Doug Lea
- * @author Josh Bloch
- * @since 1.6
- * @param <E> the type of elements held in this collection
- */
-
-public interface Deque<E> extends Queue<E> {
- /**
- * Inserts the specified element at the front of this deque if it is
- * possible to do so immediately without violating capacity restrictions.
- * When using a capacity-restricted deque, it is generally preferable to
- * use method {@link #offerFirst}.
- *
- * @param e the element to add
- * @throws IllegalStateException if the element cannot be added at this
- * time due to capacity restrictions
- * @throws ClassCastException if the class of the specified element
- * prevents it from being added to this deque
- * @throws NullPointerException if the specified element is null and this
- * deque does not permit null elements
- * @throws IllegalArgumentException if some property of the specified
- * element prevents it from being added to this deque
- */
- void addFirst(E e);
-
- /**
- * Inserts the specified element at the end of this deque if it is
- * possible to do so immediately without violating capacity restrictions.
- * When using a capacity-restricted deque, it is generally preferable to
- * use method {@link #offerLast}.
- *
- * <p>This method is equivalent to {@link #add}.
- *
- * @param e the element to add
- * @throws IllegalStateException if the element cannot be added at this
- * time due to capacity restrictions
- * @throws ClassCastException if the class of the specified element
- * prevents it from being added to this deque
- * @throws NullPointerException if the specified element is null and this
- * deque does not permit null elements
- * @throws IllegalArgumentException if some property of the specified
- * element prevents it from being added to this deque
- */
- void addLast(E e);
-
- /**
- * Inserts the specified element at the front of this deque unless it would
- * violate capacity restrictions. When using a capacity-restricted deque,
- * this method is generally preferable to the {@link #addFirst} method,
- * which can fail to insert an element only by throwing an exception.
- *
- * @param e the element to add
- * @return <tt>true</tt> if the element was added to this deque, else
- * <tt>false</tt>
- * @throws ClassCastException if the class of the specified element
- * prevents it from being added to this deque
- * @throws NullPointerException if the specified element is null and this
- * deque does not permit null elements
- * @throws IllegalArgumentException if some property of the specified
- * element prevents it from being added to this deque
- */
- boolean offerFirst(E e);
-
- /**
- * Inserts the specified element at the end of this deque unless it would
- * violate capacity restrictions. When using a capacity-restricted deque,
- * this method is generally preferable to the {@link #addLast} method,
- * which can fail to insert an element only by throwing an exception.
- *
- * @param e the element to add
- * @return <tt>true</tt> if the element was added to this deque, else
- * <tt>false</tt>
- * @throws ClassCastException if the class of the specified element
- * prevents it from being added to this deque
- * @throws NullPointerException if the specified element is null and this
- * deque does not permit null elements
- * @throws IllegalArgumentException if some property of the specified
- * element prevents it from being added to this deque
- */
- boolean offerLast(E e);
-
- /**
- * Retrieves and removes the first element of this deque. This method
- * differs from {@link #pollFirst pollFirst} only in that it throws an
- * exception if this deque is empty.
- *
- * @return the head of this deque
- * @throws NoSuchElementException if this deque is empty
- */
- E removeFirst();
-
- /**
- * Retrieves and removes the last element of this deque. This method
- * differs from {@link #pollLast pollLast} only in that it throws an
- * exception if this deque is empty.
- *
- * @return the tail of this deque
- * @throws NoSuchElementException if this deque is empty
- */
- E removeLast();
-
- /**
- * Retrieves and removes the first element of this deque,
- * or returns <tt>null</tt> if this deque is empty.
- *
- * @return the head of this deque, or <tt>null</tt> if this deque is empty
- */
- E pollFirst();
-
- /**
- * Retrieves and removes the last element of this deque,
- * or returns <tt>null</tt> if this deque is empty.
- *
- * @return the tail of this deque, or <tt>null</tt> if this deque is empty
- */
- E pollLast();
-
- /**
- * Retrieves, but does not remove, the first element of this deque.
- *
- * This method differs from {@link #peekFirst peekFirst} only in that it
- * throws an exception if this deque is empty.
- *
- * @return the head of this deque
- * @throws NoSuchElementException if this deque is empty
- */
- E getFirst();
-
- /**
- * Retrieves, but does not remove, the last element of this deque.
- * This method differs from {@link #peekLast peekLast} only in that it
- * throws an exception if this deque is empty.
- *
- * @return the tail of this deque
- * @throws NoSuchElementException if this deque is empty
- */
- E getLast();
-
- /**
- * Retrieves, but does not remove, the first element of this deque,
- * or returns <tt>null</tt> if this deque is empty.
- *
- * @return the head of this deque, or <tt>null</tt> if this deque is empty
- */
- E peekFirst();
-
- /**
- * Retrieves, but does not remove, the last element of this deque,
- * or returns <tt>null</tt> if this deque is empty.
- *
- * @return the tail of this deque, or <tt>null</tt> if this deque is empty
- */
- E peekLast();
-
- /**
- * Removes the first occurrence of the specified element from this deque.
- * If the deque does not contain the element, it is unchanged.
- * More formally, removes the first element <tt>e</tt> such that
- * <tt>(o==null ? e==null : o.equals(e))</tt>
- * (if such an element exists).
- * Returns <tt>true</tt> if this deque contained the specified element
- * (or equivalently, if this deque changed as a result of the call).
- *
- * @param o element to be removed from this deque, if present
- * @return <tt>true</tt> if an element was removed as a result of this call
- * @throws ClassCastException if the class of the specified element
- * is incompatible with this deque (optional)
- * @throws NullPointerException if the specified element is null and this
- * deque does not permit null elements (optional)
- */
- boolean removeFirstOccurrence(Object o);
-
- /**
- * Removes the last occurrence of the specified element from this deque.
- * If the deque does not contain the element, it is unchanged.
- * More formally, removes the last element <tt>e</tt> such that
- * <tt>(o==null ? e==null : o.equals(e))</tt>
- * (if such an element exists).
- * Returns <tt>true</tt> if this deque contained the specified element
- * (or equivalently, if this deque changed as a result of the call).
- *
- * @param o element to be removed from this deque, if present
- * @return <tt>true</tt> if an element was removed as a result of this call
- * @throws ClassCastException if the class of the specified element
- * is incompatible with this deque (optional)
- * @throws NullPointerException if the specified element is null and this
- * deque does not permit null elements (optional)
- */
- boolean removeLastOccurrence(Object o);
-
- // *** Queue methods ***
-
- /**
- * Inserts the specified element into the queue represented by this deque
- * (in other words, at the tail of this deque) if it is possible to do so
- * immediately without violating capacity restrictions, returning
- * <tt>true</tt> upon success and throwing an
- * <tt>IllegalStateException</tt> if no space is currently available.
- * When using a capacity-restricted deque, it is generally preferable to
- * use {@link #offer(Object) offer}.
- *
- * <p>This method is equivalent to {@link #addLast}.
- *
- * @param e the element to add
- * @return <tt>true</tt> (as specified by {@link Collection#add})
- * @throws IllegalStateException if the element cannot be added at this
- * time due to capacity restrictions
- * @throws ClassCastException if the class of the specified element
- * prevents it from being added to this deque
- * @throws NullPointerException if the specified element is null and this
- * deque does not permit null elements
- * @throws IllegalArgumentException if some property of the specified
- * element prevents it from being added to this deque
- */
- boolean add(E e);
-
- /**
- * Inserts the specified element into the queue represented by this deque
- * (in other words, at the tail of this deque) if it is possible to do so
- * immediately without violating capacity restrictions, returning
- * <tt>true</tt> upon success and <tt>false</tt> if no space is currently
- * available. When using a capacity-restricted deque, this method is
- * generally preferable to the {@link #add} method, which can fail to
- * insert an element only by throwing an exception.
- *
- * <p>This method is equivalent to {@link #offerLast}.
- *
- * @param e the element to add
- * @return <tt>true</tt> if the element was added to this deque, else
- * <tt>false</tt>
- * @throws ClassCastException if the class of the specified element
- * prevents it from being added to this deque
- * @throws NullPointerException if the specified element is null and this
- * deque does not permit null elements
- * @throws IllegalArgumentException if some property of the specified
- * element prevents it from being added to this deque
- */
- boolean offer(E e);
-
- /**
- * Retrieves and removes the head of the queue represented by this deque
- * (in other words, the first element of this deque).
- * This method differs from {@link #poll poll} only in that it throws an
- * exception if this deque is empty.
- *
- * <p>This method is equivalent to {@link #removeFirst()}.
- *
- * @return the head of the queue represented by this deque
- * @throws NoSuchElementException if this deque is empty
- */
- E remove();
-
- /**
- * Retrieves and removes the head of the queue represented by this deque
- * (in other words, the first element of this deque), or returns
- * <tt>null</tt> if this deque is empty.
- *
- * <p>This method is equivalent to {@link #pollFirst()}.
- *
- * @return the first element of this deque, or <tt>null</tt> if
- * this deque is empty
- */
- E poll();
-
- /**
- * Retrieves, but does not remove, the head of the queue represented by
- * this deque (in other words, the first element of this deque).
- * This method differs from {@link #peek peek} only in that it throws an
- * exception if this deque is empty.
- *
- * <p>This method is equivalent to {@link #getFirst()}.
- *
- * @return the head of the queue represented by this deque
- * @throws NoSuchElementException if this deque is empty
- */
- E element();
-
- /**
- * Retrieves, but does not remove, the head of the queue represented by
- * this deque (in other words, the first element of this deque), or
- * returns <tt>null</tt> if this deque is empty.
- *
- * <p>This method is equivalent to {@link #peekFirst()}.
- *
- * @return the head of the queue represented by this deque, or
- * <tt>null</tt> if this deque is empty
- */
- E peek();
-
-
- // *** Stack methods ***
-
- /**
- * Pushes an element onto the stack represented by this deque (in other
- * words, at the head of this deque) if it is possible to do so
- * immediately without violating capacity restrictions, returning
- * <tt>true</tt> upon success and throwing an
- * <tt>IllegalStateException</tt> if no space is currently available.
- *
- * <p>This method is equivalent to {@link #addFirst}.
- *
- * @param e the element to push
- * @throws IllegalStateException if the element cannot be added at this
- * time due to capacity restrictions
- * @throws ClassCastException if the class of the specified element
- * prevents it from being added to this deque
- * @throws NullPointerException if the specified element is null and this
- * deque does not permit null elements
- * @throws IllegalArgumentException if some property of the specified
- * element prevents it from being added to this deque
- */
- void push(E e);
-
- /**
- * Pops an element from the stack represented by this deque. In other
- * words, removes and returns the first element of this deque.
- *
- * <p>This method is equivalent to {@link #removeFirst()}.
- *
- * @return the element at the front of this deque (which is the top
- * of the stack represented by this deque)
- * @throws NoSuchElementException if this deque is empty
- */
- E pop();
-
-
- // *** Collection methods ***
-
- /**
- * Removes the first occurrence of the specified element from this deque.
- * If the deque does not contain the element, it is unchanged.
- * More formally, removes the first element <tt>e</tt> such that
- * <tt>(o==null ? e==null : o.equals(e))</tt>
- * (if such an element exists).
- * Returns <tt>true</tt> if this deque contained the specified element
- * (or equivalently, if this deque changed as a result of the call).
- *
- * <p>This method is equivalent to {@link #removeFirstOccurrence}.
- *
- * @param o element to be removed from this deque, if present
- * @return <tt>true</tt> if an element was removed as a result of this call
- * @throws ClassCastException if the class of the specified element
- * is incompatible with this deque (optional)
- * @throws NullPointerException if the specified element is null and this
- * deque does not permit null elements (optional)
- */
- boolean remove(Object o);
-
- /**
- * Returns <tt>true</tt> if this deque contains the specified element.
- * More formally, returns <tt>true</tt> if and only if this deque contains
- * at least one element <tt>e</tt> such that
- * <tt>(o==null ? e==null : o.equals(e))</tt>.
- *
- * @param o element whose presence in this deque is to be tested
- * @return <tt>true</tt> if this deque contains the specified element
- * @throws ClassCastException if the type of the specified element
- * is incompatible with this deque (optional)
- * @throws NullPointerException if the specified element is null and this
- * deque does not permit null elements (optional)
- */
- boolean contains(Object o);
-
- /**
- * Returns the number of elements in this deque.
- *
- * @return the number of elements in this deque
- */
- public int size();
-
- /**
- * Returns an iterator over the elements in this deque in proper sequence.
- * The elements will be returned in order from first (head) to last (tail).
- *
- * @return an iterator over the elements in this deque in proper sequence
- */
- Iterator<E> iterator();
-
- /**
- * Returns an iterator over the elements in this deque in reverse
- * sequential order. The elements will be returned in order from
- * last (tail) to first (head).
- *
- * @return an iterator over the elements in this deque in reverse
- * sequence
- */
- Iterator<E> descendingIterator();
-
-}
Deleted: trunk/core/src/classpath/java/java/util/DuplicateFormatFlagsException.java
===================================================================
--- trunk/core/src/classpath/java/java/util/DuplicateFormatFlagsException.java 2007-08-11 19:55:49 UTC (rev 3391)
+++ trunk/core/src/classpath/java/java/util/DuplicateFormatFlagsException.java 2007-08-11 19:58:14 UTC (rev 3392)
@@ -1,88 +0,0 @@
-/* DuplicateFormatFlagsException.java
- Copyright (C) 2005 Free Software Foundation, Inc.
-
-This file is part of GNU Classpath.
-
-GNU Classpath is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-GNU Classpath is distributed in the hope that it will be useful, but
-WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with GNU Classpath; see the file COPYING. If not, write to the
-Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
-02110-1301 USA.
-
-Linking this library statically or dynamically with other modules is
-making a combined work based on this library. Thus, the terms and
-conditions of the GNU General Public License cover the whole
-combination.
-
-As a special exception, the copyright holders of this library give you
-permission to link this library with independent modules to produce an
-executable, regardless of the license terms of these independent
-modules, and to copy and distribute the resulting executable under
-terms of your choice, provided that you also meet, for each linked
-independent module, the terms and conditions of the license of that
-module. An independent module is a module which is not derived from
-or based on this library. If you modify this library, you may extend
-this exception to your version of the library, but you are not
-obligated to do so. If you do not wish to do so, delete this
-exception statement from your version. */
-
-
-package java.util;
-
-/**
- * Thrown when the flags supplied to the {@link Formatter#format()}
- * method of a {@link Formatter} contain duplicates.
- *
- * @author Tom Tromey (tr...@re...)
- * @author Andrew John Hughes (gnu...@me...)
- * @since 1.5
- */
-public class DuplicateFormatFlagsException
- extends IllegalFormatException
-{
- private static final long serialVersionUID = 18890531L;
-
- /**
- * The flags which contain a duplicate.
- *
- * @serial the flags containing a duplicate.
- */
- // Note: name fixed by serialization.
- private String flags;
-
- /**
- * Constructs a new <code>DuplicateFormatFlagsException</code>
- * which specifies that the supplied set of flags contains a
- * duplicate.
- *
- * @param flags the flags containing a duplicate.
- * @throws NullPointerException if <code>flags</code> is null.
- */
- public DuplicateFormatFlagsException(String flags)
- {
- super("Duplicate flag passed in " + flags);
- if (flags == null)
- throw new
- NullPointerException("Null flags value passed to constructor.");
- this.flags = flags;
- }
-
- /**
- * Returns the flags which contain a duplicate.
- *
- * @return the flags.
- */
- public String getFlags()
- {
- return flags;
- }
-}
Deleted: trunk/core/src/classpath/java/java/util/EmptyStackException.java
===================================================================
--- trunk/core/src/classpath/java/java/util/EmptyStackException.java 2007-08-11 19:55:49 UTC (rev 3391)
+++ trunk/core/src/classpath/java/java/util/EmptyStackException.java 2007-08-11 19:58:14 UTC (rev 3392)
@@ -1,69 +0,0 @@
-/* EmptyStackException.java -- Attempt to pop from an empty stack
- Copyright (C) 1998, 1999, 2001, 2005 Free Software Foundation, Inc.
-
-This file is part of GNU Classpath.
-
-GNU Classpath is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-GNU Classpath is distributed in the hope that it will be useful, but
-WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with GNU Classpath; see the file COPYING. If not, write to the
-Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
-02110-1301 USA.
-
-Linking this library statically or dynamically with other modules is
-making a combined work based on this library. Thus, the terms and
-conditions of the GNU General Public License cover the whole
-combination.
-
-As a special exception, the copyright holders of this library give you
-permission to link this library with independent modules to produce an
-executable, regardless of the license terms of these independent
-modules, and to copy and distribute the resulting executable under
-terms of your choice, provided that you also meet, for each linked
-independent module, the terms and conditions of the license of that
-module. An independent module is a module which is not derived from
-or based on this library. If you modify this library, you may extend
-this exception to your version of the library, but you are not
-obligated to do so. If you do not wish to do so, delete this
-exception statement from your version. */
-
-
-package java.util;
-
-/* Written using "Java Class Libraries", 2nd edition, ISBN 0-201-31002-3
- * "The Java Language Specification", ISBN 0-201-63451-1
- * plus online API docs for JDK 1.2 beta from http://www.javasoft.com.
- */
-
-/**
- * This exception is thrown by the Stack class when an attempt is made to pop
- * or otherwise access elements from an empty stack.
- *
- * @author Warren Levy (wa...@cy...)
- * @author Eric Blake (eb...@em...)
- * @see Stack
- * @since 1.0
- * @status updated to 1.4
- */
-public class EmptyStackException extends RuntimeException
-{
- /**
- * Compatible with JDK 1.0.
- */
- private static final long serialVersionUID = 5084686378493302095L;
-
- /**
- * Constructs an EmptyStackException with no detail message.
- */
- public EmptyStackException()
- {
- }
-}
Deleted: trunk/core/src/classpath/java/java/util/Enumeration.java
===================================================================
--- trunk/core/src/classpath/java/java/util/Enumeration.java 2007-08-11 19:55:49 UTC (rev 3391)
+++ trunk/core/src/classpath/java/java/util/Enumeration.java 2007-08-11 19:58:14 UTC (rev 3392)
@@ -1,82 +0,0 @@
-/* Enumeration.java -- Interface for enumerating lists of objects
- Copyright (C) 1998, 1999, 2001, 2004, 2005
- Free Software Foundation, Inc.
-
-This file is part of GNU Classpath.
-
-GNU Classpath is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-GNU Classpath is distributed in the hope that it will be useful, but
-WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with GNU Classpath; see the file COPYING. If not, write to the
-Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
-02110-1301 USA.
-
-Linking this library statically or dynamically with other modules is
-making a combined work based on this library. Thus, the terms and
-conditions of the GNU General Public License cover the whole
-combination.
-
-As a special exception, the copyright holders of this library give you
-permission to link this library with independent modules to produce an
-executable, regardless of the license terms of these independent
-modules, and to copy and distribute the resulting executable under
-terms of your choice, provided that you also meet, for each linked
-independent module, the terms and conditions of the license of that
-module. An independent module is a module which is not derived from
-or based on this library. If you modify this library, you may extend
-this exception to your version of the library, but you are not
-obligated to do so. If you do not wish to do so, delete this
-exception statement from your version. */
-
-package java.util;
-
-/* Written using "Java Class Libraries", 2nd edition, ISBN 0-201-31002-3
- * "The Java Language Specification", ISBN 0-201-63451-1.
- * Status: Believed complete and correct
- */
-
-/**
- * Interface for lists of objects that can be returned in sequence. Successive
- * objects are obtained by the nextElement method.
- * <p>
- * As of Java 1.2, the Iterator interface provides the same functionality, but
- * with shorter method names and a new optional method to remove items from the
- * list. If writing for 1.2, consider using Iterator instead. Enumerations over
- * the new collections classes, for use with legacy APIs that require them, can
- * be obtained by the enumeration method in class Collections.
- *
- * @author Warren Levy (wa...@cy...)
- * @author Eric Blake (eb...@em...)
- * @see Iterator
- * @see Hashtable
- * @see Vector
- * @since 1.0
- * @status updated to 1.4
- */
-public interface Enumeration<E>
-{
- /**
- * Tests whether there are elements remaining in the enumeration.
- *
- * @return true if there is at least one more element in the enumeration,
- * that is, if the next call to nextElement will not throw a
- * NoSuchElementException.
- */
- boolean hasMoreElements();
-
- /**
- * Obtain the next element in the enumeration.
- *
- * @return the next element in the enumeration
- * @throws NoSuchElementException if there are no more elements
- */
- E nextElement();
-}
Deleted: trunk/core/src/classpath/java/java/util/Iterator.java
===================================================================
--- trunk/core/src/classpath/java/java/util/Iterator.java 2007-08-11 19:55:49 UTC (rev 3391)
+++ trunk/core/src/classpath/java/java/util/Iterator.java 2007-08-11 19:58:14 UTC (rev 3392)
@@ -1,87 +0,0 @@
-/* Iterator.java -- Interface for iterating over collections
- Copyright (C) 1998, 2001, 2004, 2005 Free Software Foundation, Inc.
-
-This file is part of GNU Classpath.
-
-GNU Classpath is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-GNU Classpath is distributed in the hope that it will be useful, but
-WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with GNU Classpath; see the file COPYING. If not, write to the
-Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
-02110-1301 USA.
-
-Linking this library statically or dynamically with other modules is
-making a combined work based on this library. Thus, the terms and
-conditions of the GNU General Public License cover the whole
-combination.
-
-As a special exception, the copyright holders of this library give you
-permission to link this library with independent modules to produce an
-executable, regardless of the license terms of these independent
-modules, and to copy and distribute the resulting executable under
-terms of your choice, provided that you also meet, for each linked
-independent module, the terms and conditions of the license of that
-module. An independent module is a module which is not derived from
-or based on this library. If you modify this library, you may extend
-this exception to your version of the library, but you are not
-obligated to do so. If you do not wish to do so, delete this
-exception statement from your version. */
-
-
-package java.util;
-
-/**
- * An object which iterates over a collection. An Iterator is used to return
- * the items once only, in sequence, by successive calls to the next method.
- * It is also possible to remove elements from the underlying collection by
- * using the optional remove method. Iterator is intended as a replacement
- * for the Enumeration interface of previous versions of Java, which did not
- * have the remove method and had less conveniently named methods.
- *
- * @author Original author unknown
- * @author Eric Blake (eb...@em...)
- * @see Collection
- * @see ListIterator
- * @see Enumeration
- * @since 1.2
- * @status updated to 1.4
- */
-public interface Iterator<E>
-{
- /**
- * Tests whether there are elements remaining in the collection. In other
- * words, calling <code>next()</code> will not throw an exception.
- *
- * @return true if there is at least one more element in the collection
- */
- boolean hasNext();
-
- /**
- * Obtain the next element in the collection.
- *
- * @return the next element in the collection
- * @throws NoSuchElementException if there are no more elements
- */
- E next();
-
- /**
- * Remove from the underlying collection the last element returned by next
- * (optional operation). This method can be called only once after each
- * call to <code>next()</code>. It does not affect what will be returned
- * by subsequent calls to next.
- *
- * @throws IllegalStateException if next has not yet been called or remove
- * has already been called since the last call to next.
- * @throws UnsupportedOperationException if this Iterator does not support
- * the remove operation.
- */
- void remove();
-}
Deleted: trunk/core/src/classpath/java/java/util/List.java
===================================================================
--- trunk/core/src/classpath/java/java/util/List.java 2007-08-11 19:55:49 UTC (rev 3391)
+++ trunk/core/src/classpath/java/java/util/List.java 2007-08-11 19:58:14 UTC (rev 3392)
@@ -1,451 +0,0 @@
-/* List.java -- An ordered collection which ...
[truncated message content] |