All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class jnfs.RemoteFileOutputStream

java.lang.Object
   |
   +----java.io.OutputStream
           |
           +----jnfs.RemoteFileOutputStream

public class RemoteFileOutputStream
extends OutputStream
implements Serializable, Runnable
An output stream for writing data to a file remotely. Conforms to the same interface as an OutputStream.

Version:
$Id: RemoteFileOutputStream.java,v 2.9 1997/05/20 17:59:39 mjr Exp $
Author:
Michael John Radwin
See Also:
FileServer, OutputStream

Method Index

 o close()
Closes this file output stream and releases any system resources associated with this stream.
 o finalize()
Ensures that the close method of this file output stream is called when there are no more references to this stream.
 o flush()
Flushes this output stream and forces any buffered output bytes to be written out.
 o run()
Used internally by the RemoteFileOutputStream to send data over the network.
 o write(byte[], int, int)
Writes len bytes from the specified byte array starting at offset off to this file output stream.
 o write(int)
Writes the specified byte to this file output stream.

Methods

 o write
 public synchronized void write(byte b[],
                                int off,
                                int len) throws IOException
Writes len bytes from the specified byte array starting at offset off to this file output stream.

Parameters:
b - the data.
off - the start offset in the data.
len - the number of bytes to write.
Throws: IOException
if an I/O error occurs.
Overrides:
write in class OutputStream
 o write
 public synchronized void write(int b) throws IOException
Writes the specified byte to this file output stream.

Parameters:
b - the byte to be written.
Throws: IOException
if an I/O error occurs.
Overrides:
write in class OutputStream
 o close
 public synchronized void close() throws IOException
Closes this file output stream and releases any system resources associated with this stream.

Throws: IOException
if the data could not be flushed.
Throws: RemoteException
if the file could not be closed.
Overrides:
close in class OutputStream
 o flush
 public synchronized void flush() throws IOException
Flushes this output stream and forces any buffered output bytes to be written out.

Throws: IOException
if an I/O error occurs.
Overrides:
flush in class OutputStream
 o finalize
 protected void finalize() throws IOException
Ensures that the close method of this file output stream is called when there are no more references to this stream.

Throws: IOException
if an I/O error occurs.
Overrides:
finalize in class Object
See Also:
close
 o run
 public void run()
Used internally by the RemoteFileOutputStream to send data over the network.


All Packages  Class Hierarchy  This Package  Previous  Next  Index