com.sun.squawk.io.j2me.dserror
Class Protocol

java.lang.Object
  extended by com.sun.squawk.io.ConnectionBase
      extended by com.sun.squawk.io.j2me.dserror.Protocol
All Implemented Interfaces:
Connection, OutputConnection

public class Protocol
extends ConnectionBase
implements OutputConnection

This Generic Connection Framework Protocol class writes to the FRC Driver Station error pane.

Author:
dw29446

Field Summary
protected  boolean opened
           
 
Constructor Summary
Protocol()
           
 
Method Summary
 Connection open(java.lang.String protocol, java.lang.String name, int mode, boolean timeouts)
          Open the connection
 java.io.OutputStream openOutputStream()
          Returns an output stream for this socket.
 
Methods inherited from class com.sun.squawk.io.ConnectionBase
close, openDataOutputStream
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface javax.microedition.io.OutputConnection
openDataOutputStream
 
Methods inherited from interface javax.microedition.io.Connection
close
 

Field Detail

opened

protected boolean opened
Constructor Detail

Protocol

public Protocol()
Method Detail

open

public Connection open(java.lang.String protocol,
                       java.lang.String name,
                       int mode,
                       boolean timeouts)
                throws java.io.IOException
Open the connection

Parameters:
name - the target for the connection
timeouts - a flag to indicate that the called wants timeout exceptions
Throws:
java.io.IOException

openOutputStream

public java.io.OutputStream openOutputStream()
                                      throws java.io.IOException
Returns an output stream for this socket.

Specified by:
openOutputStream in interface OutputConnection
Overrides:
openOutputStream in class ConnectionBase
Returns:
an output stream for writing bytes to this socket.
Throws:
java.io.IOException - if an I/O error occurs when creating the output stream.