DCT Lightfoot v3 API specification

com.dctl.j2me.io.socket
Class SocketOutputStream

java.lang.Object
  |
  +--java.io.OutputStream
        |
        +--com.dctl.j2me.io.socket.SocketOutputStream
All Implemented Interfaces:
Writable

public class SocketOutputStream
extends OutputStream

This reads data in from a socket


Method Summary
 void close()
          Close the socket
 void flush()
          flush the buffer
 void write(byte[] buf, int off, int len)
          Write a buffer to the stream
 void write(int b)
          Write one byte to the stream
 
Methods inherited from class java.io.OutputStream
write
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

close

public void close()
           throws IOException
Close the socket

Overrides:
close in class OutputStream
Throws:
IOException - if there is an error

write

public void write(int b)
           throws IOException
Write one byte to the stream

Specified by:
write in interface Writable
Specified by:
write in class OutputStream
Parameters:
b - The byte to write
Throws:
IOException - if there is an error

write

public void write(byte[] buf,
                  int off,
                  int len)
           throws IOException
Write a buffer to the stream

Specified by:
write in interface Writable
Overrides:
write in class OutputStream
Parameters:
buf - The buffer
off - The offset into the buffer
len - The maximum length to write
Returns:
the number of bytes read or -1 if EOF
Throws:
IOException - if there is an error

flush

public void flush()
           throws IOException
flush the buffer

Overrides:
flush in class OutputStream
Throws:
IOException - if there is an error

DCT Lightfoot v3 API specification

DCT Lightfoot v3 API specification