summaryrefslogtreecommitdiffstats
path: root/libjava/java/util
Commit message (Collapse)AuthorAgeFilesLines
...
* * java/util/jar/JarFile.java (manifest): Not final.mark2002-12-034-128/+180
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (manifestRead): New field. (JarFile): Don't read Manifest in constructor. (getManifest): New method. (JarEnumeration.nextElement): Use new method. (getEntry): Likewise. * java/util/zip/ZipFile.java (name): Final. (raf): Likewsie. (entries): Change type to Hashtable. (closed): New field. (ZipFile): Don't read enties in constructor. (readEntries): Use Hashtable. (close): Set new close flag and set entries to null inside synchronized block. (entries): Contruct enumeration using new getEntries() method and entries Hashtable. (getEntryIndex): Removed. (getEntries): New method. (getEntry): Use new getEntries() method and entries Hastable. (getInputStream): Likewise. (size): Return getEntries().size(). (ZipEntryEnumeration): Wrap entries Hashtable elements. * java/util/zip/ZipEntry.java (cal): Don't initialize. (time): Removed (dostime): New field. (zipFileIndex): Removed. (ZipEntry(ZipEntry)): Copy dostime. (setDOSTime): Now final and doesn't convert dos time. (getDOSTime): Likewise. (setTime): Convert dos time. (getTime): Likewise. (getCalendar): New method. (setExtra): Use setTime(). * java/util/zip/ZipInputStream.java (getNextEntry): Format error msg. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@59785 138bc75d-0d04-0410-961f-82ee72b054a4
* 2002-11-27 Julian Dolby <dolby@us.ibm.com>tromey2002-11-271-0/+2
| | | | | | | | * java/util/Locale.java (toString): Improve efficiency if country and variant are both empty. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@59590 138bc75d-0d04-0410-961f-82ee72b054a4
* For PR libgcj/8593:tromey2002-11-161-15/+21
| | | | | | | | | * java/util/zip/GZIPInputStream.java (read): Check file size. Look in inflater for remaining input bytes. (read4): Added buf and offset arguments. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@59145 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/io/Externalizable.java, java/io/FilePermission.java,tromey2002-11-103-135/+155
| | | | | | | | | | | java/io/ObjectStreamConstants.java, java/io/Serializable.java, java/io/SerializablePermission.java, java/text/Format.java, java/util/AbstractMap.java, java/util/HashMap.java, java/util/LinkedHashMap.java, javax/naming/BinaryRefAddr.java: New versions from Classpath. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@58996 138bc75d-0d04-0410-961f-82ee72b054a4
* 2002-11-10 Anthony Green <green@redhat.com>tromey2002-11-101-1/+2
| | | | | | | * java/util/jar/Attributes.java (Name): Fix name check. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@58992 138bc75d-0d04-0410-961f-82ee72b054a4
* From svens@it.uu.se. For PR libgcj/8481.tromey2002-11-071-2/+2
| | | | | | | * java/util/Random.java (nextInt(int)): Only use 31 bits. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@58876 138bc75d-0d04-0410-961f-82ee72b054a4
* GNU Classpath merge.mark2002-11-033-11/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2002-10-31 Stephen Crawley <crawley@dstc.edu.au> * java/lang/Double.java (valueOf): Return new Double(parseDouble(s)). 2002-10-31 Wu Gansha <gansha.wu@intel.com>: * java/util/ArrayList.java (readObject, writeObject): Only read/write size items. 2002-10-31 Wu Gansha <gansha.wu@intel.com>: * java/io/DataInputStream.java (convertFromUTF): Give StringBuffer an initial estimated size to avoid enlarge buffer frequently. 2002-10-31 Wu Gansha <gansha.wu@intel.com>: * java/lang/reflect/Proxy.java (ProxyType): Set loader to System ClassLoader when null. (ProxyType.hashCode): Loader null check no longer needed. (ProxyType.sameTypes): New method. (ProxyType.equals): Use new method. 2002-10-31 Mark Wielaard <mark@klomp.org> * java/net/URLDecoder.java (decode): Initialize Stringbuffer size to length of String. * java/net/URLEncoder.java (encode): Likewise. 2002-10-31 Mark Wielaard <mark@klomp.org> * java/util/zip/ZipInputStream.java (getNextEntry): Throw IOException when stream is closed. (closeEntry): Likewise. (read): Likewise. * java/util/zip/ZipOutputStream.java (putNextEntry): Throw ZipException when no entry active. (closeEntry): Likewise. (write): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@58772 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/util/zip/ZipFile.java (readLeShort): Take and use DataInput asmark2002-10-311-39/+58
| | | | | | | | | | | | | | | argument. (readLeShort): Likewise and use byte[]. (readLeInt): Likewise. (readEntries): Use new versions of methods and use byte[] for reading a complete zip entry. Add ZipFile name to exceptions. (entries): Add ZipFile name to exceptions. (getEntry): Likewise. (checkLocalHeader): Use new versions of methods and add ZipFile name to exceptions. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@58697 138bc75d-0d04-0410-961f-82ee72b054a4
* Fix for PR libgcj/8234:tromey2002-10-162-0/+2
| | | | | | | | * java/util/zip/natInflater.cc (reset): Reset avail_in. * java/util/zip/natDeflater.cc (reset): Reset avail_in. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@58205 138bc75d-0d04-0410-961f-82ee72b054a4
* 2002-09-25 Jesse Rosenstock <jmr@ugcs.caltech.edu>tromey2002-09-251-0/+16
| | | | | | | | * java/util/TimeZone.java (getDSTSavings): New method. Fixes PR libgcj/7786. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@57518 138bc75d-0d04-0410-961f-82ee72b054a4
* 2002-09-25 Jesse Rosenstock <jmr@ugcs.caltech.edu>tromey2002-09-251-2/+8
| | | | | | | | | | | | | Fix for PR libgcj/7766: * java/util/zip/ZipInputStream.java (entryAtEOF): New field. (getNextEntry): Set it. (closeEntry): Likewise. (read): Likewise. (close): Likewise. (available): Use it. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@57513 138bc75d-0d04-0410-961f-82ee72b054a4
* Fix for PR libgcj/6576:tromey2002-09-231-83/+125
| | | | | | | | | | | | * java/util/ResourceBundle.java (tryBundle): Cache `null' if we didn't find a given bundle. (getBundle): Don't require base bundle. (setParent): Removed old comment. (tryLocalBundle): Try components even if preceding components were empty. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@57442 138bc75d-0d04-0410-961f-82ee72b054a4
* 2002-09-18 Michael Koch <konqueror@gmx.de>mkoch2002-09-183-0/+241
| | | | | | | | | | | | | | | | | * java/util/regex/Matcher.java, java/util/regex/Pattern.java, java/util/regex/PatternSyntaxException.java: Merge with classpath, new files. * Makefile.am (core_java_source_files): Added java/util/regex/Matcher.java, java/util/regex/Pattern.java, java/util/regex/PatternSyntaxException.java * Makefile.in: Regenerated. * include/config.h.in: Added HAVE_NET_IF_H. * java/net/natNetworkInterface.cc (getRealNetworkInterfaces): Removed #if 0 ... #endif. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@57275 138bc75d-0d04-0410-961f-82ee72b054a4
* 2002-08-30 Jesse Rosenstock <jmr@ugcs.caltech.edu>tromey2002-08-311-3/+5
| | | | | | | | * java/util/Calendar.java (getTimeInMillis, getTimeInMillis): Now public, per 1.4 spec. Fixes PR libgcj/7785. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@56696 138bc75d-0d04-0410-961f-82ee72b054a4
* * gcj/javaprims.h: Updated class declaration list.tromey2002-06-181-168/+0
| | | | | | | | | | * Makefile.in: Rebuilt. * Makefile.am (core_java_source_files): Removed BasicMapEntry.java. * java/util/BasicMapEntry.java: Removed. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@54753 138bc75d-0d04-0410-961f-82ee72b054a4
* * gcj/javaprims.h: Updated class declaration list.tromey2002-06-1825-1068/+1693
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Makefile.in: Rebuilt. * Makefile.am (core_java_source_files): Added PropertyPermissionCollection.java. * java/lang/Thread.java (group, name): Now package-private. * java/lang/ThreadGroup.java: Re-merge with Classpath. * java/util/AbstractList.java: Likewise. * java/util/AbstractMap.java: Likewise. * java/util/Calendar.java: Likewise. * java/util/Collections.java: Likewise. * java/util/HashMap.java: Likewise. * java/util/Hashtable.java: Likewise. * java/util/LinkedHashMap.java: Likewise. * java/util/LinkedList.java: Likewise. * java/util/List.java: Likewise. * java/util/ListResourceBundle.java: Likewise. * java/util/Map.java: Likewise. * java/util/Observable.java: Likewise. * java/util/Properties.java: Likewise. * java/util/PropertyPermission.java: Likewise. * java/util/PropertyPermissionCollection.java: Likewise. * java/util/PropertyResourceBundle.java: Likewise. * java/util/Random.java: Likewise. * java/util/SimpleTimeZone.java: Likewise. * java/util/StringTokenizer.java: Likewise. * java/util/TimerTask.java: Likewise. * java/util/TreeMap.java: Likewise. * java/util/WeakHashMap.java: Likewise. * java/util/jar/Attributes.java: Likewise. * java/util/jar/JarException.java: Likewise. * java/util/jar/Manifest.java: Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@54743 138bc75d-0d04-0410-961f-82ee72b054a4
* * gcj/javaprims.h: Updated class declaration list.tromey2002-06-173-15/+110
| | | | | | | | | | | * Makefile.in: Rebuilt. * Makefile.am (core_java_source_files): Added new file. * java/util/EventListenerProxy.java: New file. * java/util/EventListener.java: Re-merge with Classpath. * java/util/EventObject.java: Re-merge with Classpath. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@54720 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/lang/RuntimeException.java: Re-merge with Classpath.tromey2002-06-1610-106/+143
| | | | | | | | | | | | | | | | * java/util/ArrayList.java: Likewise. * java/util/Arrays.java: Likewise. * java/util/BitSet.java: Likewise. * java/util/Dictionary.java: Likewise. * java/util/IdentityHashMap.java: Likewise. * java/util/MissingResourceException.java: Likewise. * java/util/Observer.java: Likewise. * java/util/TooManyListenersException.java: Likewise. * java/util/zip/DataFormatException.java: Likewise. * java/util/zip/ZipException.java: Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@54680 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/util/zip/InflaterInputStream.java (read): Loop if data hastromey2002-06-158-787/+1332
| | | | | | | | | | | | | | | | | been read but none output by inflater. * java/util/zip/natDeflater.cc (reset): Set is_finished. * java/util/zip/natInflater.cc (reset): Set dist_needed and is_finished. * java/util/zip/ZipOutputStream.java: Replaced with Classpath version. * java/util/zip/ZipFile.java: Replaced with Classpath version. * java/util/zip/ZipEntry.java: Replaced with Classpath version. * java/util/zip/ZipInputStream.java: Replaced with Classpath version. * java/util/zip/ZipConstants.java: Replaced with Classpath version. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@54653 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/util/natTimeZone.cc: Include <stdio.h>.tromey2002-06-041-0/+2
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@54258 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/lang/natRuntime.cc: Don't include sys/time.h and time.h.tromey2002-05-141-0/+15
| | | | | | | | * java/util/natTimeZone.cc: Include sys/time.h and time.h here. Include platform.h. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@53443 138bc75d-0d04-0410-961f-82ee72b054a4
* Fixes PR libgcj/6389:tromey2002-05-132-3/+174
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Makefile.in: Rebuilt. * Makefile.am (nat_source_files): Added natTimeZone.cc. * java/util/natTimeZone.cc: New file. * java/util/TimeZone.java (getDefaultTimeZoneId): New method. * java/lang/System.java: Merged with Classpath. * java/lang/Runtime.java: Merged with Classpath. * java/lang/natSystem.cc (setErr0): Renamed from setErr; don't run security check. (setIn0): Renamed from setIn; don't run security check. (setOut0): Renamed from setOut; don't run security check. (file_encoding, getpwuid_adaptor, getSystemTimeZone, init_properties): Moved to natRuntime.cc. Moved many includes to natRuntime.cc. (isWordsBigEndian): New method. * java/lang/natRuntime.cc: Include Long.h, also other includes previously in natSystem.cc. (maxMemory): New function. (exitInternal): Renamed from `_exit'. (exit): Removed. (init): Don't set finalize_on_exit. (exitInternal): Use `finalizeOnExit'. (file_encoding, getpwuid_adaptor): New functions from natSystem.cc. (insertSystemProperties): New method, renamed from System::init_properties. Don't set user.timezone. (_load): Don't call checkLink. (execInternal): New method. (availableProcessors): Likewise. (nativeGetLibname): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@53429 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/util/ResourceBundle.java: New version from Classpath.tromey2002-05-092-644/+765
| | | | | | | * java/util/Locale.java: Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@53351 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/util/AbstractMap.java (putAll): Use entrySet size.mark2002-04-081-5/+5
| | | | | | | (toString): Explicitly use getKey() and getValue(). git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@52008 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/util/Hashtable.java (contains): Remove NullPointer check.mark2002-04-071-14/+8
| | | | | | | | (containsValue): Add NullPointer check. (remove): Always throw NullPointerException when key is null. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@51994 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/util/ArrayList.java (addAll(int,Collection)): System.arraycopymark2002-04-072-5/+17
| | | | | | | | | | | | | all of the remaining elements. * java/util/Vector.java (addAll(int,Collection)): Likewise. (removeRange): If toIndex == fromIndex do nothing, if toIndex < fromIndex throw IndexOutIfBoundsException. (removeAll): Always throw NullPointerException when collection is null. (retrainAll): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@51979 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/util/ArrayList.jva (removeRange): If toIndex == fromIndex domark2002-04-061-3/+7
| | | | | | | nothing, if toIndex < fromIndex throw IndexOutIfBoundsException. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@51947 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/util/Arrays.java (qsort): Fix off-by-one errors and use ofbryce2002-04-041-42/+49
| | | | | | | incorrect "hi" value when count > 40. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@51854 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/util/IdentityHashMap.java (put): Set new threshold correctlybryce2002-04-021-1/+1
| | | | | | | when resizing table. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@51751 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/util/BitSet.java (BitSet(int)): if nbits < 0 throwmark2002-04-011-6/+9
| | | | | | | | | | | | | NegativeArraySizeException (clear(int)): Use sign extended shift. (flip(int)): Likewise. (get(int)): Likewise. (nextClearBit(int)): Likewise. (nextSetBit(int)): Likewise. (set(int)): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@51701 138bc75d-0d04-0410-961f-82ee72b054a4
* 2002-03-23 Michael Smith <msmith@spinnakernet.com>tromey2002-03-231-3/+3
| | | | | | | | * java/util/GregorianCalendar.java (minimums, maximums): Correct MONTH entry. Fixes PR libgcj/6045. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@51232 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/util/Timer (TaskQueue.stop): set elements to zero.mark2002-03-031-0/+1
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@50254 138bc75d-0d04-0410-961f-82ee72b054a4
* 2002-02-14 Mark Wielaard <mark@klomp.org>mark2002-02-142-5/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * java/math/BigInteger.java: import gnu.java.math.MPN not the whole package as a workaround for gcj 3.0.x 2002-02-14 Mark Wielaard <mark@klomp.org> * java/security/BasicPermission.java: extends with fully qualified classname as workaround for gcj 3.0.4. 2002-02-14 Eric Blake <ebb9@email.byu.edu> * java/net/DatagramSocketImpl.java (setOption, getOption): Work around gcj bug of wrong emitted qualifier for inherited method. * java/net/SocketImpl.java (setOption, getOption): Ditto. * java/util/WeakHashMap.java (WeakEntrySet): Add non-private constructor to reduce amount of emitted bytecode. While this happens to work around a jikes 1.15 bug, it is still a useful patch even for correct compilers. * java/rmi/server/RMIClassLoader.java (MyClassLoader): Ditto. * gnu/java/rmi/server/UnicastRemoteCall.java (DummyObjectOutputStream, DummyObjectInputStream): Ditto. 2002-02-14 Eric Blake <ebb9@email.byu.edu> * java/net/DatagramSocketImpl.java: Reformat (no code changes). * java/net/SocketImpl.java: Ditto. * java/rmi/server/RMIClassLoader.java: Ditto. * gnu/java/rmi/server/UnicastRemoteCall.java: Ditto. 2002-02-14 Mark Wielaard <mark@klomp.org> Thanks to Takashi Okamoto * java/util/Arrays.java (ArrayList.indexOf()): this.equals(). * java/util/Arrays.java (ArrayList.lastIndexOf()): Likewise. * java/util/WeakHashMap.java (WeakEntry.getEntry()): this.get(). git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@49778 138bc75d-0d04-0410-961f-82ee72b054a4
* Add license clarification.mark2002-01-2283-415/+1328
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@49104 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/util/zip/ZipOutputStream.java (putNextEntry): Clearbothner2002-01-191-0/+1
| | | | | | | uncompressed_size in readiness for next entry. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@49014 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/util/IdentityHashMap.java (IdentityHashMap): Removedtromey2002-01-161-4/+2
| | | | | | | | commented code. (hash): Correctly compute initial value for `h'. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@48925 138bc75d-0d04-0410-961f-82ee72b054a4
* Collections drop from Classpath:bryce2001-12-1524-6122/+11216
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2001-12-15 Bryce McKinlay <bryce@waitaki.otago.ac.nz> * java/util/BitSet.java (and): Fix off-by-one bug, don't skip part of the bitset. (andNot): Likewise. (xor): Likewise. 2001-12-15 Bryce McKinlay <bryce@waitaki.otago.ac.nz> * java/util/LinkedList.java (LinkedListItr.add): Don't skip the next entry. 2001-12-15 Eric Blake <ebb9@email.byu.edu> * java/util/TreeMap.java (removeNode): Fix bug in node removal. 2001-12-15 Bryce McKinlay <bryce@waitaki.otago.ac.nz> * java/util/AbstractCollection.java (containsAll): Use size of the correct collection for loop bound. * java/util/AbstractList.java (iterator.next): Increment pos after calling get on backing list. (listIterator.next): Likewise. * java/util/LinkedList.java (addLastEntry): Don't increment size before checking for size == 0. (addFirstEntry): Rearrange to match addLastEntry. (add): Do not increment size before inserting the new entry. * java/util/AbstractCollection.java (addAll): Use size of the correct collection for loop bound. 2001-12-15 Bryce McKinlay <bryce@waitaki.otago.ac.nz> * java/util/AbstractSet.java (removeAll): Fix scoping thinko. * java/util/HashMap.java (putAllInternal): Set size here. * java/util/Hashtable.java (putAllInternal): New method. Copy contents of a map efficiently without calling put() or putAll(). (Hashtable (map)): Use putAllInternal. (clone): Likewise. 2001-12-15 Eric Blake <ebb9@email.byu.edu> * java/util/Collections.java: * java/util/Vector.java: * java/util/WeakHashMap.java: Fix spelling errors. 2001-12-15 Eric Blake <ebb9@email.byu.edu> * java/util/AbstractCollection.java (removeAllInternal), (retainAllInternal): Add hooks for use by ArrayList. * java/util/AbstractList.java: Minor code updates. Fix some scoping. * java/util/AbstractMap.java: ditto * java/util/ArrayList.java (readObject, writeObject): ditto (removeAllInternal, retainAllInternal): Optimize. * java/util/Arrays.java: ditto * java/util/Collections.java: ditto. Change order of parameters to equals(Object, Object) to match specs. * java/util/Dictionary.java: Improve javadoc. (Dictionary): Add explicit constructor. * java/util/HashMap.java: Improve javadoc. Rearrange methods to follow order in JDK. Cleanups related to recent code migration to AbstractMap. Fix some scoping. (entrySet): Cache the result. (modCount): Ensure that this is updated correctly. * java/util/HashSet.java: Improve javadoc. Fix some scoping. (init): Add hooks for LinkedHashSet. (map): Use "" instead of Boolean.TRUE in backing map. Use package-private API where possible for less overhead. (readObject, writeObject): Fix serialization. * java/util/Hashtable.java: Improve javadoc. Fix some scoping. (entrySet, keySet, values): Cache the result. (modCount): Ensure that this is updated correctly. (contains, remove): Fix NullPointer checking to match specs. (class Enumeration): Make more like HashIterator. * java/util/IdentityHashMap.java: Minor code updates. (modCount): Ensure that this is updated correctly. (readObject, writeObject): Fix serialization. * java/util/LinkedHashMap.java: Minor code updates. Cleanups related to recent code migration to AbstractMap. * java/util/LinkedHashSet.java: New file. * java/util/LinkedList.java: (readObject, writeObject): Fix serialization. * java/util/Makefile.am: List recently added files. * java/util/Stack.java: Minor code updates. * java/util/TreeMap.java: Improve javadoc. Overhaul the class to be more efficient. Fix some scoping. Rearrange the methods. (nil): Ensure that this can be thread-safe, and make it a static final. Initialize it to be more useful as a sentinal node. (Node): Specify color in constructor. (deleteFixup, insertFixup): Improve comments and algorithm. (fabricateTree): Redesign with less overhead. (lowestGreaterThan): Add parameter first to make SubMap easier. (removeNode): Patch hole where nil was being modified. Choose predecessor instead of successor so in-place swap works. (class VerifyResult, verifyTree, verifySub, verifyError): Remove this dead code after verifying the class works. (class SubMap): Rewrite several algorithms to avoid problems with comparing nil. * java/util/TreeSet.java: Improve javadoc. Fix some scoping. (clone): Fix ClassCastException when cloning subSet(). (readObject, writeObject): Fix serialization. * java/util/WeakHashMap.java: Improve javadoc. Fix some scoping. (NULL_KEY): Make it compare as null, for ease elsewhere. (Class WeakEntry): Rename from Entry, to avoid shadowing Map.Entry. Add missing toString. (modCount): Ensure that this is updated correctly. (clear, containsValue, keySet, putAll, values, WeakHashMap(Map)): Add missing methods and constructor. 2001-12-15 Eric Blake <ebb9@email.byu.edu> * java/util/ArrayList.java (checkBoundExclusive), (checkBoundInclusive): Rename from range??clusive, to match AbstractList. * java/util/LinkedList.java (checkBoundsExclusive), (checkBoundsInclusive): ditto * java/util/Vector.java (checkBoundExclusive), (checkBoundInclusive): Move bounds checking into common methods. 2001-12-15 Eric Blake <ebb9@email.byu.edu> * java/util/AbstractList.java: (modCount): Make sure it is updated in all needed places. * java/util/ArrayList.java: Improve javadoc. Implements RandomAccess. Add serialVersionUID. Reorder methods. (modCount): Make sure it is updated in all needed places. (rangeExclusive, rangeInclusive): Add common methods for bounds check. (isEmpty): Add missing method. * java/util/Collections.java: (class SynchronizedList): Make package visible. * java/util/ConcurrentModificationException.java: Improve javadoc. * java/util/EmptyStackException.java: Improve javadoc. * java/util/LinkedList.java: Improve javadoc. (modCount): Make sure it is updated in all needed places. (rangeExclusive, rangeInclusive): Add common methods for bounds check. * java/util/NoSuchElementException.java: Improve javadoc. * java/util/Stack.java: Improve javadoc. Fix synchronization issues. (modCount): Make sure it is updated in all needed places. * java/util/Vector.java: Improve javadoc. Fix synchronization issues. Implements RandomAccess. Reorder methods. (modCount): Make sure it is updated in all needed places. (setSize): Fix according to specifications: this does not dictate the backing array size. (removeAll, retainAll): Faster implementations. 2001-12-15 Eric Blake <ebb9@email.byu.edu> * java/util/BitSet.java: Improve javadoc. (cardinality(), clear(), clear(int, int), flip(int)), (flip(int, int), get(int, int), intersects(BitSet), isEmpty()), (nextClearBit(int), nextSetBit(int), set(int, boolean)), (set(int, int), set(int, int, boolean)): Add new JDK 1.4 methods. (clone): Fix so subclasses clone correctly. 2001-12-15 Eric Blake <ebb9@email.byu.edu> * java/util/AbstractCollection.java: Improve javadoc. (AbstractCollection()): Make constructor protected. (equals(Object, Object), hashCode(Object)): Add utility methods. * java/util/AbstractList.java: Improve javadoc. (AbstractList()): Make constructor protected. (indexOf(Object)): Call listIterator(), not listIterator(int). (iterator()): Follow Sun's requirement to not use listIterator(0). (listIterator(int)): Make AbstractListItr anonymous. (subList(int, int)): Add support for RandomAccess. (SubList.add(int, Object), SubList.remove(Object)): Fix bug with modCount tracking. (SubList.addAll(Collection)): Add missing method. (SubList.listIterator(int)): Fix bugs in indexing, modCount tracking. (class RandomAccessSubList): Add new class. * java/util/AbstractMap.java: Improve javadoc. (keys, values, KEYS, VALUES, ENTRIES): Consolidate common map fields. (AbstractMap()): Make constructor protected. (equals(Object, Object), hashCode(Object)): Add utility methods. (equals(Object)): Change algorithm to entrySet().equals(m.entrySet()), as documented by Sun. (keySet(), values()): Cache the collections. * java/util/AbstractSequentialList.java: Improve javadoc. (AbstractSequentialList()): Make constructor protected. * java/util/AbstractSet.java: Improve javadoc. (AbstractSet()): Make constructor protected. (removeAll(Collection)): Add missing method. * java/util/Arrays.java: Improve javadoc, rearrange method orders. (defaultComparator): Remove, in favor of Collections.compare(Object, Object, Comparator). (binarySearch, equals, sort): Fix natural order comparison of floats and doubles. Also improve Object comparison - when comparator is null, use natural order. (fill, sort): Add missing checks for IllegalArgumentException. (sort, qsort): Fix sorting bugs, rework the code for more legibility. (mergeSort): Inline into sort(Object[], int, int, Comparator). (class ArrayList): Rename from ListImpl, and make compatible with JDK serialization. Add methods which more efficiently override those of AbstractList. * java/util/Collections: Improve javadoc. (isSequential(List)): Add and use a method for deciding between RandomAccess and sequential algorithms on lists. (class Empty*, class Synchronized*, class Unmodifiable*): Make compliant with JDK serializability. (class Singleton*, class CopiesList, class RevereseComparator), (class UnmodifiableMap.UnmodifiableEntrySet), (class *RandomAccessList): New classes for serial compatibility. (class Empty*, class Singleton*, class CopiesList): Add methods which more efficiently override those of Abstract*. (search): Inline into binarySearch(List, Object, Comparator). (binarySearch): Make sequential search only do log(n) comparisons, instead of n. (copy(List, List)): Do bounds checking before starting. (indexOfSubList, lastIndexOfSubList, list, replaceAll, rotate), (swap): Add new JDK 1.4 methods. (binarySearch, max, min, sort): Allow null comparator to represent natural ordering. (reverse(List)): Avoid unnecessary swap. (shuffle(List, Random)): Do shuffle in-place for RandomAccess lists. (SingletonList.get): Fix logic bug. (SingletonMap.entrySet): Make the entry immutable, and cache the returned set. (SynchronizedCollection, SynchronizedMap, UnmodifiableCollection), (UnmodifiableMap): Detect null pointer in construction. (SynchronizedMap, UnmodifiableMap): Cache collection views. * java/util/BasicMapEntry: Improve javadoc. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@48035 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/util/Timer.java (TaskQueue.isStopped): Remove method.mark2001-11-161-11/+10
| | | | | | | | (Scheduler.run): Try to re-schedule task and ignore exception if queue has been stopped. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@47093 138bc75d-0d04-0410-961f-82ee72b054a4
* Re-merges with Classpath, from various people:tromey2001-11-143-14/+41
| | | | | | | | | | | | | | | | | * java/lang/Double.java (parseDouble): Fixed ordering of modifiers. * java/lang/reflect/AccessibleObject.java: Javadoc, reindented. * java/lang/reflect/Member.java: Reindented. * java/lang/reflect/Modifier.java: Reindented. (toString): Only trim trailing space if text was added to StringBuffer. * java/util/ConcurrentModificationException.java: Javadoc updates. * java/util/EmptyStackException.java: Likewise. * java/util/NoSuchElementException.java: Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@47018 138bc75d-0d04-0410-961f-82ee72b054a4
* Fix for PR libgcj/4859:tromey2001-11-131-2/+11
| | | | | | | | | * java/util/Timer.java (TaskQueue.isStopped): New method. (Scheduler.run): Don't re-schedule task if queue has been stopped. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@46994 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/util/ResourceBundle.java (class Security): Now static.bryce2001-11-051-1/+1
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@46781 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/util/ResourceBundle.java (getClassContext): Removed.bryce2001-11-042-56/+36
| | | | | | | | | | (Security): New class, extends SecurityManger. (getBundle): Use Security.getCallingClassLoader instead of getClassContext. * java/util/natResourceBundle.cc: Removed. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@46761 138bc75d-0d04-0410-961f-82ee72b054a4
* 2001-11-02 Hans Boehm <Hans_Boehm@hp.com>hboehm2001-11-031-1/+1
| | | | | | | | * java/util/natResourceBundle.cc:getClassContext: return array of Class instead of array of ClassLoader. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@46727 138bc75d-0d04-0410-961f-82ee72b054a4
* * HACKING, gnu/gcj/xlib/Pixmap.java, gnu/gcj/xlib/XException.java,jsm282001-10-3113-31/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | gnu/java/rmi/rmic/RMIC.java, java/awt/Window.java, java/awt/AWTEvent.java, java/io/ByteArrayOutputStream.java, java/io/CharConversionException.java, java/io/PipedInputStream.java, java/io/PipedReader.java, java/io/PrintWriter.java, java/io/WriteAbortedException.java, java/io/natFileWin32.cc, java/lang/Class.h, java/lang/natClassLoader.cc, java/lang/natObject.cc, java/lang/Package.java, java/net/BindException.java, java/net/ConnectException.java, java/net/ProtocolException.java, java/net/SocketException.java, java/net/UnknownServiceException.java, java/security/cert/X509Certificate.java, java/security/interfaces/DSAKey.java, java/security/SecureRandom.java, java/security/SignedObject.java, java/sql/DatabaseMetaData.java, java/text/DecimalFormatSymbols.java, java/util/jar/Attributes.java, java/util/jar/JarEntry.java, java/util/jar/JarInputStream.java, java/util/jar/JarOutputStream.java, java/util/Calendar.java, java/util/Collections.java, java/util/GregorianCalendar.java, java/util/HashMap.java, java/util/List.java, java/util/Properties.java, java/util/Timer.java, java/util/Vector.java, java/util/WeakHashMap.java, javax/naming/NamingException.java, testsuite/libjava.lang/Thread_Wait.java, org/xml/sax/helpers/DefaultHandler.java, org/xml/sax/HandlerBase.java, org/xml/sax/SAXParseException.java, ChangeLog, acinclude.m4, aclocal.m4, posix-threads.cc: Fix spelling errors. * configure: Regenerate. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@46665 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/util/zip/GZIPOutputStream.java (write(int)): New method.tromey2001-10-291-1/+7
| | | | | | | Fixes PR libgcj/4728. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@46618 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/util/zip/Adler32.java: Use correct class name. (Re-mergetromey2001-10-261-1/+1
| | | | | | | from Classpath.) git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@46561 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/util/PropertyResourceBundle.java (handleGetObject): Nowtromey2001-10-242-4/+4
| | | | | | | | | public. * java/util/ListResourceBundle.java (handleGetObject): Now public and final, per spec. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@46452 138bc75d-0d04-0410-961f-82ee72b054a4
* * java/util/GregorianCalendar.java (getGregorianChange): Removedtromey2001-10-231-1/+1
| | | | | | | `date' argument. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@46423 138bc75d-0d04-0410-961f-82ee72b054a4
* * gcj/javaprims.h: Updated class list.tromey2001-10-161-392/+612
| | | | | | | * java/util/Hashtable.java: Re-merged with Classpath. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@46295 138bc75d-0d04-0410-961f-82ee72b054a4
* 2001-10-15 Bryce McKinlay <bryce@waitaki.otago.ac.nz>bryce2001-10-1613-612/+2114
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * java/util/HashMap.java (HashEntry.clone): Removed. (HashMap(Map)): Use putAllInternal. (clone): Likewise. (putAllInternal): New method. Efficient counterpart to putAll which does not call put(). * java/util/LinkedHashMap.java (rethread): Removed. (putAllInternal): New method. Clear "head" and "tail". (addEntry): New argument "callRemove". Don't call removeEldestEntry() if callRemove == false. * Makefile.am: Add new classes RandomAccess and LinkedHashMap. * Makefile.in: Rebuilt. 2001-10-15 Eric Blake <ebb9@email.byu.edu> * java/util/Collection.java: Updated javadoc. * java/util/Comparator.java: Updated javadoc. * java/util/Enumeration.java: Updated javadoc. * java/util/Iterator.java: Updated javadoc. * java/util/List.java: Updated javadoc. * java/util/ListIterator.java: Updated javadoc. * java/util/Map.java: Updated javadoc. * java/util/RandomAccess.java: New file. * java/util/Set.java: Updated javadoc. * java/util/SortedMap.java: Updated javadoc. * java/util/SortedSet.java: Updated javadoc. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@46277 138bc75d-0d04-0410-961f-82ee72b054a4
OpenPOWER on IntegriCloud