summaryrefslogtreecommitdiff
path: root/libjava/gnu/java/nio
Commit message (Collapse)AuthorAgeFilesLines
...
* 2004-03-11 Michael Koch <konqueror@gmx.de>mkoch2004-03-111-46/+63
| | | | | | | | | * gnu/java/nio/channels/natFileChannelEcos.cc: Totally reworked. This file was was just copied form java/io/natFileDescriptorEcos.cc and never changed to compile correctly. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@79320 138bc75d-0d04-0410-961f-82ee72b054a4
* 2004-03-11 Michael Koch <konqueror@gmx.de>mkoch2004-03-111-9/+32
| | | | | | | | | | | * gnu/java/nio/PipeImpl.java (SourceChannelImpl): Made final. (read): Implemented. (SinkChannelImpl): Made final. (write): Implemented. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@79315 138bc75d-0d04-0410-961f-82ee72b054a4
* * gnu/java/nio/FileLockImpl.java (fd): Remove field, replacing it by:bothner2004-02-292-32/+6
| | | | | | | | | | (ch): New FileChannelImpl field. Update constructor to match. (releaseImpl): Remove native method. Instead ... (release): Call unlock on channel. * gnu/java/nio/natFileLockImpl.cc: Removed file. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@78663 138bc75d-0d04-0410-961f-82ee72b054a4
* * gnu/java/nio/channels/FileChannelImpl.java: New class, renamedbothner2004-02-294-0/+1533
| | | | | | | | | | | | | | | | | from java/nio/channels. Don't depend on FileDescriptor. (in, out, err): New static fields. (mode): New field. (SET, CUR, READ, WRITE, APPEND, EXCL, SYNC, DSYNC): Moved constants from FileDescriptor. (by): Removed MappedByteBuffer field. (map): New working implementation. * gnu/java/nio/channels/natFileChannelPosix.cc: New file, though some code "ported" from natFileDescriptoPosix.cc. * gnu/java/nio/channels/natFileChannelEcos.cc: Likewise. * gnu/java/nio/channels/natFileChannelWin32.cc Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@78659 138bc75d-0d04-0410-961f-82ee72b054a4
* 2004-02-26 Michael Koch <konqueror@gmx.de>mkoch2004-02-261-1/+1
| | | | | | | | | | | | | | | | | | | * gnu/java/nio/FileLockImpl.java (finalize): Made protected. * java/nio/channels/FileChannel.java (MapMode.READ_ONLY): Made final. (MapMode.READ_WRITE): Made final. (MapMode.PRIVATE): Made final. * java/nio/channels/SocketChannel.java (open): Simplified code. * java/nio/channels/spi/AbstractSelectableChannel.java (registered): Unused, removed. (keyFor): Check channel is open, only locate key and not add a new one. (register): Don't delete attachments. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@78519 138bc75d-0d04-0410-961f-82ee72b054a4
* 2004-02-26 Michael Koch <konqueror@gmx.de>mkoch2004-02-261-2/+7
| | | | | | | | * gnu/java/nio/DatagramChannelImpl.java (send): Check if target address is resolved. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@78508 138bc75d-0d04-0410-961f-82ee72b054a4
* 2004-02-05 Michael Koch <konqueror@gmx.de>mkoch2004-02-052-3/+2
| | | | | | | | | | | * gnu/java/nio/NIOServerSocket.java (impl): Unused, removed. * gnu/java/nio/SocketChannelImpl.java (finnishConnect): Don't throw NoConnectionPendingException if not connected or no connection pending. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@77317 138bc75d-0d04-0410-961f-82ee72b054a4
* * gnu/java/nio/DatagramChannelImpl.javamembar2004-02-032-10/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | (inChannelOperation): New field. (isInChannelOperation): New accessor. (setInChannelOperation): New modifier. (receive): Use capacity() - position() of destination buffer instead of remaining(). Set and reset our "in channel operation indicator" before and after delegating the receive to our datagram socket. Removed testing code. Update destination buffer's current position if it is backed by a byte array (hasArray() is true). (send): Set and reset our "in channel operation indicator" before and after delegating the send to our datagram socket. Removed testing code. Update source buffer's current position if it is backed by a byte array (hasArray() is true). * gnu/java/nio/SocketChannelImpl.java (read(ByteBuffer)): Use capacity() - position() of destination buffer instead of remaining(). * java/net/DatagramSocket.java (receive): Don't throw an IllegalBlockingModeException if we have a non-blocking channel which initiated this operation. (send): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@77173 138bc75d-0d04-0410-961f-82ee72b054a4
* * gnu/java/net/PlainSocketImpl.javamembar2004-01-302-17/+50
| | | | | | | | | | | | | | | | | | | | | | | | | | | | (inChannelOperation): New field. (isInChannelOperation): New accessor. (setInChannelOperation): New modifier. * gnu/java/nio/ServerSocketChannelImpl.java (accept): Set and reset our server socket's PlainSocketImpl's "in channel operation" indicator before and after delegating the accept to our server socket. * gnu/java/nio/SocketChannelImpl.java (connect): Set and reset our socket's PlainSocketImpl's "in channel operation" indicator before and after delegating the operation to our socket. (read): Likewise. (write): Likewise. * java/net/ServerSocket.java (implAccept): Don't throw an IllegalBlockingModeException if we have a non-blocking channel which initiated this accept operation. * java/net/Socket.java (connect): Don't throw an IllegalBlockingModeException if we have a non-blocking channel which initiated this connect operation. * java/nio/channels/spi/AbstractSelectableChannel.java (configureBlocking): Only call implConfigureBlocking() if the desired blocking mode is different from our current one. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@76956 138bc75d-0d04-0410-961f-82ee72b054a4
* 2004-01-23 Michael Koch <konqueror@gmx.de>mkoch2004-01-231-3/+1
| | | | | | | * gnu/java/nio/FileLockImpl.java: Compile fixes. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@76427 138bc75d-0d04-0410-961f-82ee72b054a4
* 2004-01-23 Michael Koch <konqueror@gmx.de>mkoch2004-01-232-6/+15
| | | | | | | | | | | | | | | | | | | | | * gnu/java/nio/FileLockImpl.java: Fixed filename in copyright. (released): Removed. (finalize): New method. * gnu/java/nio/natFileLockImpl.cc (releaseImpl): Implemented. * java/nio/channels/FileChannelImpl.java: Reworked imports. (lock): Implemented. (lockImpl): New method. (tryLock): Implemented. (tryLockImpl): New method. * java/nio/channels/natFileChannelImpl.cc (lockImpl): New method. (tryLockImpl): New method. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@76422 138bc75d-0d04-0410-961f-82ee72b054a4
* 2004-01-07 Michael Koch <konqueror@gmx.de>mkoch2004-01-073-7/+4
| | | | | | | | | | | | | | | | | | | | | | | * gnu/java/nio/DatagramChannelImpl.java (blocking): Removed. (DatagramChannelImpl): Call configureBlocking(). (implConfigureBlocking): Dont initialize blocking. * gnu/java/nio/ServerSocketChannelImpl.java (blocking): Removed. (ServerSocketChannelImpl): Call configureBlocking(). (implConfigureBlocking): Dont initialize blocking. * gnu/java/nio/SocketChannelImpl.java (blocking): Removed. (SocketChannelImpl): Call configureBlocking(). (implConfigureBlocking): Dont initialize blocking. (connect): Use isBlocking(). * java/nio/channels/spi/AbstractSelectableChannel.java (configureBlocking): Use blockingLock() instead of LOCK. Set blocking after successfully called implConfigureBlocking(). (register): Use blockingLock() instead of LOCK. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@75507 138bc75d-0d04-0410-961f-82ee72b054a4
* * gnu/java/nio/SelectorImpl.javamembar2003-12-201-79/+208
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (selectThreadMutex): New field. (selectThread): New field. (unhandledWakeup): New field. (implCloseSelector): Added skeleton code which synchronizes as per Sun JRE JavaDoc. (keys): Throw ClosedSelectorException if selector is closed. (selectNow): Added comment that we're faking out an immediate select with a one-microsecond-timeout one. (select): Use 0 instead of -1 for infinite timeout. (implSelect): Changed comment in declaration. (select): Added synchronized to method declaration. Added synchronization and wakeup support as per Sun JRE JavaDoc. (selectedKeys): Throw ClosedSelectorException if selector is closed. (wakeup): Implemented. (deregisterCancelledKeys): Synchronize on cancelled key set before deregistering. (register): Synchronize on key set before registering. * java/nio/channels/spi/AbstractSelector.java Added import for java.nio.channels.ClosedSelectorException. (close): Added synchronized to method declaration. (cancelledKeys): Throw ClosedSelectorException if selector is closed. (cancelKey): Synchronize on cancelled key set before key. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@74879 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-12-19 Michael Koch <konqueror@gmx.de>mkoch2003-12-191-0/+67
| | | | | | | | | | | | * gnu/java/nio/ChannelOutputStream.java: New file. * java/nio/channels/Channels.java (newOutputStream): Implemented. * Makefile.am (ordinary_java_source_files) Added gnu/java/nio/ChannelOutputStream.java. * Makefile.in: Regenerated. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@74847 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-12-19 Michael Koch <konqueror@gmx.de>mkoch2003-12-191-0/+79
| | | | | | | | | | | | | * gnu/java/nio/ChannelInputStream.java: New file. * java/nio/channels/Channels.java (newInputStream): Implemented. * java/nio/channels/FileChannelImpl.java (readImpl): Only put data into buffer if something was read. * Makefile.am (ordinary_java_source_files): Added gnu/java/nio/ChannelInputStream.java. * Makefile.in: Regenerated. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@74842 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-12-19 Michael Koch <konqueror@gmx.de>mkoch2003-12-191-0/+87
| | | | | | | | | | | * gnu/java/nio/OutputStreamChannel.java: New file. * java/nio/channels/Channels.java (newChannel): Implemented. * Makefile.am (ordinary_java_source_files): Added gnu/java/nio/OutputStreamChannel.java. * Makefile.in: Regenerated. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@74840 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-12-19 Michael Koch <konqueror@gmx.de>mkoch2003-12-191-0/+88
| | | | | | | | * gnu/java/nio/InputStreamChannel.java: New file. * java/nio/channels/Channels.java (newChannel): Implemented. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@74838 138bc75d-0d04-0410-961f-82ee72b054a4
* * win32.cc (WSAEventWrapper): Implemented defaultmembar2003-12-161-65/+67
| | | | | | | | | | | | | | | | | | constructor and init() methods. (_Jv_select): Removed. * gnu/java/nio/natSelectorImplWin32.cc (helper_put_filedescriptors): Removed. (helper_get_filedescriptors): Removed. (implSelect): Implemented in terms of WSAEventWrapper and WSAWaitForMultipleEvents instead of _Jv_select(). Added support for thread interruption. * include/win32.h (WSAEventWrapper): Minor formatting changes; added default constructor declaration, init(), getFD() and getEventHandle() methods. (_Jv_select): Removed. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@74715 138bc75d-0d04-0410-961f-82ee72b054a4
* * gnu/java/nio/SocketChannelImpl.javamembar2003-12-112-14/+46
| | | | | | | | | | | | | | | | | | | (write): Removed diagnostic trace. * gnu/java/nio/natSelectorImplPosix.cc: Added includes for java.lang.Thread and java.io.InterruptedIOException. (helper_put_filedescriptors): Don't put invalid file descriptors in select set. (helper_get_filedescriptors): Clear invalid file descriptors from select set. (helper_reset): New method for clearing our file descriptor array. (implSelect): Correctly calculate timeout if specified and legal. Intercept and deal with any java.io.InterruptedIOException thrown by _Jv_select(). git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@74537 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-12-09 Michael Koch <konqueror@gmx.de>mkoch2003-12-091-1/+3
| | | | | | | | | * gnu/java/nio/SelectorImpl.java (implSelect): Throws IOException. (select): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@74468 138bc75d-0d04-0410-961f-82ee72b054a4
* * gnu/java/nio/natSelectorImplPosix.ccmembar2003-12-041-2/+4
| | | | | | | | (implSelect): A timeout of 0 means an infinite timeout. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@74259 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-12-02 Michael Koch <konqueror@gmx.de>mkoch2003-12-025-5/+25
| | | | | | | | | | | | | | | | | | * gnu/java/nio/DatagramChannelImpl.java (blocking): Initialize with true by default. * gnu/java/nio/ServerSocketChannelImpl.java (serverSocket): Made private. (blocking): Likewise. (connected): Likewise. * gnu/java/nio/SocketChannelImpl.java (connectionPending): Made private. * gnu/java/nio/FileLockImpl.java (static): Load native library (needed for classpath). * gnu/java/nio/SelectorImpl.java (static): Load native library (needed for classpath). git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@74181 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-11-22 Michael Koch <konqueror@gmx.de>mkoch2003-11-224-7/+7
| | | | | | | | | | | | | | | | | * gnu/java/nio/DatagramChannelImpl.java (getNativeFD): Use getPlainDatagramSocketImpl(). * gnu/java/nio/NIODatagramSocket.java (getPlainDatagramSocketImpl): Renamed from getImpl(). * gnu/java/nio/NIOSocket.java (getPlainSocketImpl): Renamed from getImpl(). (setChannel): Use getPlainSocketImpl(). * gnu/java/nio/SocketChannelImpl.java (SocketChannelImpl): Use getPlainSocketImpl(). (getPlainSocketImpl): Renamed from getImpl(). (getNativeFD): Use getPlainSocketImpl(). git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@73840 138bc75d-0d04-0410-961f-82ee72b054a4
* * gnu/java/nio/natSelectorImplPosix.ccmembar2003-11-131-2/+2
| | | | | | | | (helper_put_filedescriptors): Change to static linkage. (helper_get_filedescriptors): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@73545 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-11-11 Michael Koch <konqueror@gmx.de>mkoch2003-11-116-2/+181
| | | | | | | | | | | | | | | | | * gnu/java/nio/natPipeImpl.cc, gnu/java/nio/natSelectorImpl.cc: Removed * gnu/java/nio/natPipeImplEcos.cc, gnu/java/nio/natPipeImplPosix.cc, gnu/java/nio/natPipeImplWin32.cc, gnu/java/nio/natSelectorImplEcos.cc, gnu/java/nio/natSelectorImplPosix.cc, gnu/java/nio/natSelectorImplWin32.cc: New files * configure.in: Create links for gnu/java/nio/natPipeImpl.cc and gnu/java/nio/natSelectorImpl.cc * configure: Regenerated. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@73446 138bc75d-0d04-0410-961f-82ee72b054a4
* * win32.cc: (_Jv_pipe) Implemented.membar2003-10-171-1/+1
| | | | | | | | | | * gnu/java/nio/natPipeImpl.cc: (nativeInit) Use _Jv_pipe instead of ::pipe. * include/posix.h: (_Jv_pipe) New inline. * include/win32.h: (_Jv_pipe) New declaration. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@72616 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-10-12 Michael Koch <konqueror@gmx.de>mkoch2003-10-123-6/+150
| | | | | | | | | | | | | | | | | | | | | | | | | * gnu/java/nio/PipeImpl.java (SourceChannelImpl): New inner class. (SinkChannelImpl): New inner class. (sink): New member variable. (source): New member variable. (PipeImpl): Add SelectorProvider argument, implemented. (nativeInit): New method. (sink): Return sink channel. (source): Return source channel. * gnu/java/nio/SelectorProviderImpl.java (openPipe): Give provider as argument to PipeImpl constructor. * java/nio/channels/spi/SelectorProvider.java (pr): Removed. (systemDefaultProvider): New member variable. (provider): Made it synchronized, use property java.nio.channels.spi.SelectorProvider. * gnu/java/nio/natPipeImpl.cc: New file. * Makefile.am (nat_source_files): Added gnu/java/nio/natPipeImpl.cc. * Makefile.in: Regenerated. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@72397 138bc75d-0d04-0410-961f-82ee72b054a4
* Really remove it.mkoch2003-10-111-25/+0
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@72346 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-10-11 Michael Koch <konqueror@gmx.de>mkoch2003-10-115-45/+174
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * gnu/java/nio/NIOSocket.java (setChannel): Initialize impl. * gnu/java/nio/ServerSocketChannelImpl.java (serverSocket): Made it a NIOServerSocket. (impl): Removed. (ServerSocketChannelImpl): Initialize only serverSocket. (initServerSocket): Removed. (getNativeFD): Rewritten. (implConfigureBlocking): Set socket timeout and removed comment. (accept): Rewritten. * gnu/java/nio/SocketChannelImpl.java (impl): New variable. (connected): Removed. (SocketChannelImpl): Initialize impl too. (getImpl): New method. (isConnected): Rewritten. (read): Rewritten, set position in buffer correctly. (write): Set position in buffer correctly. * java/net/ServerSocket.java (getImpl): New method. * gnu/java/nio/NIOServerSocket.java, gnu/java/nio/natNIOServerSocket.cc: New files. * gnu/java/nio/natServerSocketChannelImpl.cc: Removed. * Makefile.am (ordinary_java_source_files): Added gnu/java/nio/NIOServerSocket.java. (nat_source_files): Removed gnu/java/nio/natServerSocketChannelImpl.cc and added gnu/java/nio/natNIOServerSocket.cc. * Makefile.in: Regenerated. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@72345 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-10-09 Michael Koch <konqueror@gmx.de>mkoch2003-10-094-5/+101
| | | | | | | | | | | | | | | | | | | | | * gnu/java/nio/SelectorImpl.java (register): Use ServerSocketChannelSelectionKey for server socket channels, removed unneeded comments. * gnu/java/nio/ServerSocketChannelImpl.java (ServerSocketChannelImpl): Made class public final. (impl): New member variable. (ServerSocketChannelImpl): Initialize member variables correctly. (initServerSocket): New method. (getNativeFD): Likewise. * gnu/java/nio/ServerSocketChannelSelectionKey.java, gnu/java/nio/natServerSocketChannelImpl.cc: New files. * Makefile.am (ordinary_java_source_files): Added gnu/java/nio/ServerSocketChannelSelectionKey.java. (nat_source_files): Added gnu/java/nio/natServerSocketChannelImpl.cc. * Makefile.in: Regenrated. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@72277 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-10-08 Michael Koch <konqueror@gmx.de>mkoch2003-10-081-1/+1
| | | | | | | | * gnu/java/nio/SocketChannelImpl.java (read): Write only read data to buffer. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@72232 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-09-27 Michael Koch <konqueror@gmx.de>mkoch2003-09-261-1/+1
| | | | | | | | | | * gnu/java/nio/SelectionKeyImpl.java (ch): Make package-private again. Jikes found this bug. Jeff Sturm submitted PR12426 for this to bugzilla to fix this bug in gcj. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@71841 138bc75d-0d04-0410-961f-82ee72b054a4
* Fix build failure.jsturm2003-09-261-6/+6
| | | | | | | | | * gnu/java/nio/SelectorImpl.java (getFDsAsArray): Use getNativeFD(). (select): Likewise. (register): Use DatagramChannelSelectionKey, SocketChannelSelectionKey. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@71812 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-09-25 Michael Koch <konqueror@gmx.de>mkoch2003-09-255-4/+129
| | | | | | | | | | | | | | | | | | | | | | * gnu/java/nio/DatagramChannelImpl.java (getNativeFD): New method. * gnu/java/nio/SelectionKeyImpl.java (SelectionKeyImpl): Class made abstract. (fd): Removed. (SelectionKeyImpl): Remove fd argument. (getNativeFD): New method. * gnu/java/nio/SocketChannelImpl.java (getNativeFD): New method. gnu/java/nio/DatagramChannelSelectionKey.java, * gnu/java/nio/SocketChannelSelectionKey.java: New files. * Makefile.am (ordinary_java_source_files): Added new files gnu/java/nio/DatagramChannelSelectionKey.java and gnu/java/nio/SocketChannelSelectionKey.java. * Makefile.in: Regenerated. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@71797 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-09-25 Michael Koch <konqueror@gmx.de>mkoch2003-09-252-10/+10
| | | | | | | | | | | | * gnu/java/nio/SelectorImpl.java (implSelect): Renamed from java_do_select. (select): Call native implSelect() and add support for Thread interruption. * gnu/java/nio/natSelectorImpl.cc (implSelect): Renamed from java_do_select. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@71781 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-09-25 Michael Koch <konqueror@gmx.de>mkoch2003-09-252-68/+25
| | | | | | | | | | | | | | | | | | | | * gnu/java/nio/SelectorImpl.java (selectNow): Made final, throws IOException. (select): Likewise. (getFDsAsArray): Made final. (selectedKeys): Likewise. (wakeup): Likewise. (deregisterCancelledKeys): Likewise. (register): Likewise. (ass): Removed. (add_selected): Removed. * gnu/java/nio/natSelectorImpl.cc: No need to include bstring.h or gcj/cni.h. (helper_put_filedescriptors): Rewritten. (helper_get_filedescriptors): Rewritten. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@71779 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-09-25 Michael Koch <konqueror@gmx.de>mkoch2003-09-255-84/+387
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * gnu/java/nio/DatagramChannelImpl.java (DatagramChannelImpl): Made class final. (blocking): Made private. (socket): Made it a NIODatagramSocket and private. (DatagramChannelImpl): create NIODatagramSocket instead of DatagramSocket. (implConfigureBlocking): Set socket timeout. (connect): Check that channel is not closed. (write): Implemented. (write): Rewritten. (read): Implemented. (read): Rewritten. (receive): Implemented. (send): Implemented. * gnu/java/nio/SelectionKeyImpl.java (readyOps): Made private. (interestOps): Made private. (impl): Made private. (ch): Made private. (readyOps): Check if selection key is valid. (interestOps): Likewise. * gnu/java/nio/SelectorImpl.java (closed): Removed. (keys): Made private. (selected): Made private. (finalize): New method. (implCloseSelector): Rewritten. (keys): Return unmodifiable Set. (deregisterCancelledKeys): Fixed typo in method name. * gnu/java/nio/SocketChannelImpl.java (SocketChannelImpl): Made class final. (socket): Made it a NIOSocket and private. (blocking): Made private. (connected): Made private. (connectionPending): New member variable. (SocketChannelImpl): New implementation. (finalizer): Use isConnected(). (connect): Rewritten. (finishConnect): Throws IOException, implemented. (isConnectionPending): Return connectionPending. (read): Rewritten. (write): Rewritten. * gnu/java/nio/NIOConstants.java: New file. * Makefile.am (ordinary_java_source_files): Added gnu/java/nio/NIOConstants.java. * Makefile.in: Regenerated. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@71769 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-09-19 Michael Koch <konqueror@gmx.de>mkoch2003-09-192-0/+147
| | | | | | | | | | | | * gnu/java/nio/NIODatagramSocket.java, gnu/java/nio/NIOSocket.java: New files. * Makefile.am (ordinary_java_source_files): Added gnu/java/nio/NIODatagramSocket.java and gnu/java/nio/NIOSocket.java. * Makefile.in: Regenerated. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@71592 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-07-13 Michael Koch <konqueror@gmx.de>mkoch2003-07-132-493/+0
| | | | | | | | | | | | | | | | | | | | | | | | | * gnu/java/nio/FileChannelImpl.java, gnu/java/nio/natFileChannelImpl.cc: Removed. * java/io/FileInputStream.java, java/io/FileOutputStream.java, java/io/RandomAccessFile.java, java/nio/MappedByteBufferImpl.java: Import java.nio.channels.FileChannelImpl instead of gnu.java.nio.FileChannelImpl. * java/nio/channels/FileChannelImpl.java, java/nio/channels/natFileChannelImpl.cc: New files. * Makefile.am (ordinary_java_source_files): Removed gnu/java/nio/FileChannelImpl.java and added java/nio/channels/FileChannelImpl.java. (nat source_files): Removed gnu/java/nio/natFileChannelImpl.cc and added java/nio/channels/natFileChannelImpl.cc. * Makefile.in: Regenerated. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@69296 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-06-27 Michael Koch <konqueror@gmx.de>mkoch2003-06-271-6/+0
| | | | | | | | * gnu/java/nio/FileChannelImpl.java (write): Removed. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@68572 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-06-20 Michael Koch <konqueror@gmx.de>mkoch2003-06-203-599/+3
| | | | | | | | | | | | | | | | | | | * gnu/java/nio/MappedByteFileBuffer.java, gnu/java/nio/natMappedByteFileBuffer.cc: Removed * java/nio/MappedByteBufferImpl.java: New file. * gnu/java/nio/FileChannelImpl.java: Use MappedByteBufferImpl instead of MappedByteFileBuffer. * Makefile.am (ordinary_java_source_files): Removed gnu/java/nio/MappedByteFileBuffer.java and added java/nio/MappedByteBufferImpl.java. (nat_source_files): Removed gnu/java/nio/natMappedByteFileBuffer.cc * Makefile.in: Regenerated. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@68259 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-06-19 Michael Koch <konqueror@gmx.de>mkoch2003-06-192-51/+90
| | | | | | | | | | | | | | | | | | | | | | | | * gnu/java/nio/DatagramChannelImpl.java (fd): Removed. (blocking): New member variable. (socket): Likewise. (DatagramChannelImpl): Throws IOException, initialize socket. (socket):Implemented. (implCloseSelectableChannel): Throws IOException, implemented. (implConfigureBlocking): Likewise. (connect): Likewise. (disconnect): Likewise. (isConnected): Likewise. (write): Likewise. (read): Likewise. (receive): Throws IOException. (send): Likewise. * gnu/java/nio/SocketChannelImpl.java (read): Implemented. (write): Implemented. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@68208 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-06-19 Michael Koch <konqueror@gmx.de>mkoch2003-06-192-5/+7
| | | | | | | | | | | | | * gnu/java/nio/FileChannelImpl.java (map_address): Made public. (FileChannelImpl): Merged with classpath. * gnu/java/nio/natFileChannelImpl.cc (nio_mmap_file): Commented out unused arguments. (nio_unmmap_file): Likewise. (niu_msync): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@68186 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-06-18 Michael Koch <konqueror@gmx.de>mkoch2003-06-185-242/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * gnu/java/nio/SelectorImpl.java (register): Use fd with value 0 for now, will be fixed later. * gnu/java/nio/ServerSocketChannelImpl.java (fd): Removed. (local_port): Removed. (InetSocketAddress): Removed. (ServerSocketChannelImpl): Just initialize internal socket object. (implCloseSelectableChannel): Close internal socket object. (implConfigureBlocking): Added comment. (accept): Use jaba.net stuff to accept socket. * gnu/java/nio/SocketChannelImpl.java (fd): Removed. (local_port): Removed. (InetSocketAddress): Removed. (SocketCreate): Removed. (SocketConnect): Removed. (SocketBind): Removed. (SocketListen): Removed. (SocketAvailable): Removed. (SocketClose): Removed. (SocketRead): Removed. (SocketWrite): Removed. (SocketChannelImpl): Just initialize internal socket object. (implCloseSelectableChannel): Close internal socket object. (implConfigureBlocking): Fixed implementation, added comment. (connect): Use internal socket object to connect. (socket): No need for sanity checks. (read): Comment out some stuff, this will be reimplemented in the next commit. (write): Likewise. * gnu/java/nio/natFileChannelImpl.cc (nio_mmap_file): Line wrapped. * gnu/java/nio/natSocketChannelImpl.cc: Removed. * Makefile.am (nat_source_files): Removeded gnu/java/nio/natSocketChannelImpl.cc. * Makefile.in: Regenerated. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@68145 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-06-14 Michael Koch <konqueror@gmx.de>mkoch2003-06-144-42/+20
| | | | | | | | | | | | | | | | | | * gnu/java/nio/FileChannelImpl.java (map_address): Removed incorrect comment. * gnu/java/nio/SelectorImpl.java (register): Remove code duplication and code for file channel handling. * gnu/java/nio/ServerSocketChannelImpl.java (serverSocket): Renamed from sock_object. (ServerSocketChannel): Initialize serverSocket. (socket): Return serverSocket. * gnu/java/nio/SocketChannelImpl.java (socket): Renamed from sock_object. (isConnectionPenging): Simplified. (socket): Return socket. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@67940 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-05-20 Michael Koch <konqueror@gmx.de>mkoch2003-05-2016-2880/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * gnu/java/nio/ByteBufferImpl.java, gnu/java/nio/CharBufferImpl.java, gnu/java/nio/CharViewBufferImpl.java, gnu/java/nio/DirectByteBufferImpl.java, gnu/java/nio/DoubleBufferImpl.java, gnu/java/nio/DoubleViewBufferImpl.java, gnu/java/nio/FloatBufferImpl.java, gnu/java/nio/FloatViewBufferImpl.java, gnu/java/nio/IntBufferImpl.java, gnu/java/nio/IntViewBufferImpl.java, gnu/java/nio/LongBufferImpl.java, gnu/java/nio/LongViewBufferImpl.java, gnu/java/nio/natDirectByteBufferImpl.cc, gnu/java/nio/ShortBufferImpl.java, gnu/java/nio/ShortViewBufferImpl.java: Moved files to java/nio. * gnu/java/nio/SocketChannelImpl.java * java/nio/ByteBuffer.java, java/nio/CharBuffer.java, java/nio/DoubleBuffer.java, java/nio/FloatBuffer.java, java/nio/IntBuffer.java, java/nio/LongBuffer.java, java/nio/ShortBuffer.java: Dont import anything. * java/nio/ByteBufferImpl.java, java/nio/CharBufferImpl.java, java/nio/CharViewBufferImpl.java, java/nio/DirectByteBufferImpl.java, java/nio/DoubleBufferImpl.java, java/nio/DoubleViewBufferImpl.java, java/nio/FloatBufferImpl.java, java/nio/FloatViewBufferImpl.java, java/nio/IntBufferImpl.java, java/nio/IntViewBufferImpl.java, java/nio/LongBufferImpl.java, java/nio/LongViewBufferImpl.java, java/nio/natDirectByteBufferImpl.cc, java/nio/ShortBufferImpl.java, java/nio/ShortViewBufferImpl.java: Moved from gnu/java/nio. * Makefile.am (ordinary_java_source_files): Moved files from gnu/java/nio to java/nio. (nat_source_files): Moved natDirectByteBufferImpl.cc from gnu/java/nio to java/nio. * Makefile.in: Regenerated. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@66990 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-05-19 Michael Koch <konqueror@gmx.de>mkoch2003-05-193-65/+66
| | | | | | | | | | | | | | | | | | | | * gnu/java/nio/ByteBufferImpl.java (putLong): Fixed conversion to bytes. (putDouble): Fixed conversion to bytes. * gnu/java/nio/DirectByteBufferImpl.java (putLong): Fixed conversion to bytes. (putDouble): Fixed conversion to bytes. * gnu/java/nio/FileLockImpl.java (isValid): Reformatted. * java/nio/Buffer.java (Buffer): Fixed off-by-one bug in handling mark. * java/nio/ByteBuffer.java: Added newline. * java/nio/CharBuffer.java (toString): Don't use relative get to get string data. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@66946 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-05-14 Michael Koch <konqueror@gmx.de>mkoch2003-05-146-46/+85
| | | | | | | | | | | | | | | | | | | | | | | | | | * gnu/java/nio/FileLockImpl.java (released): New member variable. (FileLockImpl): Initialize released. (releaseImpl): New native method. (release): Implemented. * gnu/java/nio/SelectorImpl.java: Reformatted. * gnu/java/nio/SelectionKeyImpl.java: Reformatted. * gnu/java/nio/ServerSocketChannelImpl.java: Reformatted. (accept): Throws IOException. * gnu/java/nio/SocketChannelImpl.java: Reformatted. (implConfigureBlocking): Throws IOException. (connect): Likewise. (read): Likewise. (write): Likewise. * gnu/java/nio/natFileLockImpl.cc: New file. * java/nio/channels/FileLock.java: Reformatted. * Makefile.am: (ordinary_java_source_files): Added gnu/java/nio/FileLockImpl.java. (nat_source_files): Added gnu/java/nio/natFileLockImpl.cc. * Makefile.in: Regenerated. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@66799 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-05-13 Michael Koch <konqueror@gmx.de>mkoch2003-05-136-30/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * gnu/java/nio/CharViewBufferImpl.java (CharViewBufferImpl): Fixed super constructor call, initialize offset. (get): Shift bits to the right direction. (put): Likewise. * gnu/java/nio/DoubleViewBufferImpl.java (DoubleViewBufferImpl): Fixed super constructor call, initialize offset. (get): Shift bits to the right direction. (put): Likewise. * gnu/java/nio/FloatViewBufferImpl.java (FloatViewBufferImpl): Fixed super constructor call, initialize offset. (get): Shift bits to the right direction. (put): Likewise. * gnu/java/nio/IntViewBufferImpl.java (IntViewBufferImpl): Fixed super constructor call, initialize offset. (get): Shift bits to the right direction. (put): Likewise. * gnu/java/nio/LongViewBufferImpl.java (LongViewBufferImpl): Fixed super constructor call, initialize offset. (get): Shift bits to the right direction. (put): Likewise. * gnu/java/nio/ShortViewBufferImpl.java (ShortViewBufferImpl): Fixed super constructor call, initialize offset. (get): Shift bits to the right direction. (put): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@66780 138bc75d-0d04-0410-961f-82ee72b054a4
* 2003-05-13 Michael Koch <konqueror@gmx.de>mkoch2003-05-131-2/+3
| | | | | | | | | * gnu/java/nio/natDirectByteBufferImpl.cc (allocateImpl): jlong -> RawData*. (freeImpl): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@66760 138bc75d-0d04-0410-961f-82ee72b054a4