harmony-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Paulex Yang (JIRA)" <j...@apache.org>
Subject [jira] Updated: (HARMONY-42) com.ibm.io.nio.FileChannel is not fully implemented
Date Wed, 25 Jan 2006 14:01:10 GMT
     [ http://issues.apache.org/jira/browse/HARMONY-42?page=all ]

Paulex Yang updated HARMONY-42:
-------------------------------

    Attachment: Harmony42-java_io_FileChannelFactory-patch.txt
                Harmony42-java_io_FileOutputStream-patch.txt

A POC refactor patch for java.io.FileOutputStream is attached, with some minor changes on
FileChannelFactory. java.io.FileInputStream and RandomAccessFile can be easily refactored
in similiar style. 

As a completement to my comment on the issue 40, The FileChannelImpl's implCloseChannel()
can look like:
    protected void implCloseChannel() throws IOException {
        if(stream instanceof Closeable){
            ((Closeable)stream).close();
        }
        fileSystem.close(handle);
    }
   
    and the FileChannelImpl's super class, AbstractInterruptibleChannel's close method can
be:

	public synchronized final void close() throws IOException {
		if (!closed) {
                    closed = true;
                    implCloseChannel();
		}	
	}
    

> com.ibm.io.nio.FileChannel is not fully implemented
> ---------------------------------------------------
>
>          Key: HARMONY-42
>          URL: http://issues.apache.org/jira/browse/HARMONY-42
>      Project: Harmony
>         Type: Bug
>   Components: Classlib
>     Reporter: Paulex Yang
>     Assignee: Tim Ellison
>  Attachments: Harmony42-IFileSystem-patch.txt, Harmony42-IMemorySystem-patch.txt, Harmony42-java_io_FileChannelFactory-patch.txt,
Harmony42-java_io_FileOutputStream-patch.txt, IFileSystem.java
>
> Many functions of FileChannel, such as memory map, transfer, gathering/scattering I/O
are not implemented. Further, three classes in java.io, FileInputStream FileOutputStream,
and RandomAccessFile, are related to java.nio.FileChannel, so that they can be refactored
to base on same JNI interface, just like the network channels and sockets. 

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


Mime
View raw message