org.jSyncManager.Transport
Class DebugTransport
- Serializable
public class DebugTransport
A transport wrapper used for debugging purposes.
This wrapper can be used by the SLP protocol stack to wrap the data I/O
routines to dump the incoming and outgoing byte data to stdout.
Note that applications shouldn't try to instantiate this class -- it won't work.
void | close()- Closes the implemented transport.
|
protected JPanel | constructConfigPanel()- Constructs this transports configuration panel.
|
void | flush()- Flushes the input buffer of any remaining data.
|
String | getResourceBundleName()- Returns the fully-qualified classname for the resources package to use for this transport.
|
String | getTransportDescription()- Returns the description for this Transport Interface.
|
String | getTransportExceptionText(TransportException ex)- Retrieves error information for a given TransportInitException.
|
String | getTransportName()- Returns the name of this Transport Interface.
|
void | initialize()- Initialize the port.
|
void | initialize(Properties properties, int id)- Initialize the port.
|
void | open()- Opens a read/write connection to the implemented transport.
|
byte | readByte()- Read a single byte from the underlying data stream.
|
void | writeBytes(data[] )- Write an array of bytes to the underlying data stream.
|
close, constructConfigPanel, flush, getConfigPanel, getResourceBundle, getResourceBundleName, getTransportDescription, getTransportExceptionText, getTransportName, initialize, initialize, isConnected, loadResourceBundle, open, readByte, setConnected, writeBytes |
count
protected int count
A value to hold the incoming byte count.
realTransport
protected SLPTransportInterface realTransport
A handle to the transport class we're wrapping.
constructConfigPanel
protected JPanel constructConfigPanel()
Constructs this transports configuration panel.
- constructConfigPanel in interface SLPTransportInterface
- a null object -- this class doesn't provide a configuration JPanel.
getResourceBundleName
public String getResourceBundleName()
Returns the fully-qualified classname for the resources package to use for this transport.
class here.
- getResourceBundleName in interface SLPTransportInterface
- a String object containing the fully qualified classname for a ResoureBundle
class to use for this transport.
getTransportDescription
public String getTransportDescription()
Returns the description for this Transport Interface.
This method will return a string containing the description for
this transport interface.
- getTransportDescription in interface SLPTransportInterface
- the description for this transport interface.
getTransportExceptionText
public String getTransportExceptionText(TransportException ex)
Retrieves error information for a given TransportInitException.
- getTransportExceptionText in interface SLPTransportInterface
ex - the TransportInitException to be inspected.
- a String object containing a text explaination for the exception.
getTransportName
public String getTransportName()
Returns the name of this Transport Interface. This method will return a string containing the name of
this transport interface. This is used when searching for and selecting from one of many available
transport interfaces that are installed on the system.
- getTransportName in interface SLPTransportInterface
- the name of this transport interface.
initialize
public void initialize(Properties properties,
int id)
throws TransportExceptionInitialize the port.
- initialize in interface SLPTransportInterface
properties - a reference to the properties file containing configuration information.id - the transport ID number to load data for.
open
public void open()
throws TransportExceptionOpens a read/write connection to the implemented transport. This method should open the transport
device being implemented using default parameters.
- open in interface SLPTransportInterface
readByte
public byte readByte()
throws TransportExceptionRead a single byte from the underlying data stream. This method call should abstract the underlying
data connection stream to allow the SLP protocol to read a single byte from the stream.
- readByte in interface SLPTransportInterface
- the byte that was read from the underlying transport.
writeBytes
public void writeBytes(data[] )
throws TransportExceptionWrite an array of bytes to the underlying data stream. This method call should abstract the underlying
data connection stream to allow the SLP protocol to write an array of bytes to the stream.
- writeBytes in interface SLPTransportInterface