Commit Graph

62 Commits

Author SHA1 Message Date
1daa93d3c4 add ability to append to files 2010-08-16 09:23:48 -06:00
f0f35a920f return a useful value from InflaterInputStream.available
Note the following excerpt from PNGFileFormat.java in SWT:

     /*
     * InflaterInputStream does not consume all bytes in the stream
     * when it is closed. This may leave unread IDAT chunks. The fix
     * is to read all available bytes before closing it.
     */
     while (stream.available() > 0) stream.read();
     stream.close();

This code relies on the documented behavior of
InflaterInputStream.available, which must return "0 after EOF has been
reached, otherwise always return 1".  This is unlike
InputStream.available, which is documented to return "the number of
bytes that can be read (or skipped over) from this input stream
without blocking by the next caller of a method for this input
stream", and says nothing about how many bytes are left until the end
of stream.

This commit modifies InflaterInputStream.available to behave according
to Sun's documentation.
2010-08-04 18:54:47 -06:00
a6998238d5 Additional of several interfaces which can be used in serialization 2010-05-10 10:17:06 -06:00
JET
b6936fb597 optimized InputStreamReader.read() 2010-04-14 09:43:56 -06:00
JET
b2f5e71d22 ARM and UTF-8 work 2010-04-14 09:26:50 -06:00
2c4e229e6e convert forward slashes to back slashes in Windows paths 2010-01-11 08:31:01 -07:00
585dba004b ignore redundant calls to File{In|Out}putStream.close
Previously, we threw an IOException, which did not match Sun's behavior.
2010-01-09 18:22:16 -07:00
9a056da2f7 increase default buffer size in BufferedInputStream
The previous value of 32 bytes did not perform well.  This increases it to 4096 bytes, which matches BufferedOutputStream.
2010-01-09 18:20:15 -07:00
6118792ffd update copyright years 2009-12-02 19:08:29 -07:00
447741d6ec implement java.io.File.renameTo 2009-09-28 17:45:47 -06:00
58e3c3013a pass start and end indexes to String.getChars in Writer.write, not start and length 2009-08-13 08:55:35 -06:00
626c514373 add listFiles and isFile methods to java.io.File 2009-08-04 17:59:07 -06:00
d1018bf078 update copyright years 2009-03-15 12:02:36 -06:00
8bcc78b5b7 add InputStreamReader(InputStream,String) 2009-02-16 18:22:19 -07:00
277278b331 Fixed off by one in list method. 2009-02-03 15:28:39 -07:00
JET
e86acf4543 added separator to String and added IOException to vm.pro 2009-01-02 13:25:05 -07:00
ae75be5683 add copyright headers 2008-10-03 14:57:40 -06:00
4c307ae8c6 implement minimal, read-only versions of RandomAccessFile and ZipFile 2008-10-03 14:15:47 -06:00
a16a00a7fb implement ByteArrayOutputStream.reset 2008-09-26 15:29:38 -06:00
27efbcf5e1 fix single-byte BufferedInputStream.read to generate unsigned result 2008-09-02 14:54:34 -06:00
0ae338e74a fix various bugs in BufferedReader.readLine 2008-07-15 08:59:00 -06:00
7534459fec Stylistic tweaks 2008-07-13 21:54:07 -06:00
dcccddeb55 add FilenameFilter interface 2008-07-13 18:24:23 -06:00
2e0ca31148 implement File.list and File.mkdirs 2008-07-13 18:14:37 -06:00
14e2513590 fix some API compatibility issues in the class library 2008-05-07 17:44:43 -06:00
7dd9b96717 add additional methods and fields to class library 2008-03-20 18:40:18 -06:00
2edaa82801 prepend copyright notice and license to all source files; add license.txt and readme.txt 2008-02-19 11:06:52 -07:00
6954c9c377 Fixes for PushbackReader (which only can push back one char) and StringReader. 2007-12-18 12:19:52 -07:00
d24b633665 fix return value of ByteArrayOutputStream.size() 2007-11-27 16:59:49 -07:00
74235ea33c add ByteArrayOutputStream.size() 2007-11-27 10:30:55 -07:00
7a4cca45c2 fix subtle length vs. limit bug in ByteArrayInputStream 2007-10-31 10:11:14 -06:00
2fd2df53fd Fixed thinko in ByteArrayInputStream 2007-10-30 16:52:24 -06:00
b85c643251 Minor optimization for ByteArrayInputStream 2007-10-30 15:37:46 -06:00
907ce57975 Order of arraycopy backwards 2007-10-30 15:10:32 -06:00
df79f410f1 Optimize bulk reads from ByteArrayInputStream 2007-10-30 15:08:49 -06:00
75d4a4ff96 implement a few classpath methods required by SWT for Win32 2007-10-29 14:57:33 -06:00
b12b779c7f add support for passing properties to the VM via JNI; use vm.builtins property to specify builtin libraries 2007-10-25 12:33:43 -06:00
5bfd90cfed more system-specific tweaks for windows port 2007-10-24 10:24:02 -06:00
8ae36c05b7 lots of new instructions and bugfixes 2007-09-29 20:48:27 -06:00
0efc498837 Another place where printing null should be permitted 2007-09-27 15:21:39 -06:00
101b0c3b0e Support printing of null references 2007-09-27 15:05:55 -06:00
c7567b4081 Fixed typo 2007-09-26 11:45:44 -06:00
c174ce34b6 Added several useful classes 2007-09-26 11:27:09 -06:00
7cb3a30a91 sketch of Runtime.exec() and Calendar; misc bugfixes 2007-09-12 18:21:37 -06:00
cb03240c64 quick sketches of various SWT 3.3 dependencies 2007-09-11 19:13:05 -06:00
a4b4f36c5b various classpath updates to help SWT build 2007-08-30 17:31:32 -06:00
8b102783a6 implement File.getParent() 2007-08-28 17:39:21 -06:00
f22dda0df1 bugfixes 2007-08-14 19:14:55 -06:00
71c7013808 more bugfixes 2007-08-14 07:27:10 -06:00
587dbeb163 bugfixes 2007-08-13 20:35:49 -06:00