1.0.0

org.eclipse.soda.dk.connection
Class TraceConnection

java.lang.Object
  extended by org.eclipse.soda.dk.core.EscObject
      extended by org.eclipse.soda.dk.connection.Connection
          extended by org.eclipse.soda.dk.connection.TraceConnection
All Implemented Interfaces:
ConnectionService

public class TraceConnection
extends Connection
implements ConnectionService

Version:
1.0.0

Field Summary
 
Fields inherited from class org.eclipse.soda.dk.connection.Connection
CLIENT_WAIT_RESOURCE, CLOSE_RESOURCE, CLOSED_RESOURCE, configurationService, OPEN_RESOURCE, OPENFAILED_RESOURCE, READ_BYTES_RESOURCE, WRITE_BYTES_RESOURCE
 
Fields inherited from class org.eclipse.soda.dk.core.EscObject
CLONE_EXCEPTION_RESOURCE, EMPTY_BYTES, EMPTY_STRING, ERROR_OCCURRED_EXCEPTION_RESOURCE, ID_FILTER_KEY, ID_KEY, ID_KEY_ANY, INTEGER_TABLE, KEY_KEY, LOG_DEBUG, LOG_ERROR, LOG_INFO, LOG_TRACE, LOG_WARNING, PREFIX_KEY, RESOURCE_BUNDLE, SLEEP_EXCEPTION_RESOURCE, SYSTEM_INFO_RESOURCE, TO_STRING_CONFIGURATION_KEYS, TRACE_LEVEL_HIGH, TRACE_LEVEL_LOW, TRACE_LEVEL_MAX, TRACE_LEVEL_MIN, TRACE_LEVEL_NONE, TRACE_LEVEL_NORMAL, TRACELEVEL_KEY, UNKNOWN_ERROR_RESOURCE
 
Fields inherited from interface org.eclipse.soda.dk.connection.service.ConnectionService
CONNECTION_KEY, DEFAULT_CONNECTION, SERVICE_NAME
 
Constructor Summary
TraceConnection(ConnectionService connectionService)
          Constructs an instance of this class from the specified connection service parameter.
 
Method Summary
 void close()
          Close.
 void exit()
          Exit.
 void flush()
          Flush.
 ConnectionService getConnectionService()
          Gets the connection service value.
 boolean isOpen()
          Gets the open (boolean) value.
 void open()
          Open.
 int read(byte[] bytes)
          Read with the specified bytes parameter and return the int result.
 int read(byte[] bytes, int offset, int length)
          Read with the specified bytes, offset and length parameters and return the int result.
 void setConnectionService(ConnectionService connectionService)
          Sets the connection service value.
 java.lang.String toString()
          Returns the string value.
 void write(byte[] bytes)
          Write with the specified bytes parameter.
 void write(byte[] bytes, int offset, int count)
          Write with the specified bytes, offset and count parameters.
 
Methods inherited from class org.eclipse.soda.dk.connection.Connection
attemptRecoveryFromError, finalize, getConfigurationService, getDefaultResource, getErrorSeverity, getResource, setConfigurationService, setOpen
 
Methods inherited from class org.eclipse.soda.dk.core.EscObject
createDefaultLogService, createException, createException, createInteger, createIntegerTable, createNumber, format, getBoolean, getCurrentTimestamp, getDefaultLogService, getFloat, getInt, getLoadLibraryName, getLogDetails, getLogDetails0, getLogDetails1, getLogDetails2, getLogDetails3, getLogDetails4, getLogDetails5, getLogDetails6, getLogDetails7, getLogService, getLong, getObject, getOutputName, getSimpleClassName, getStaticBoolean, getStaticFloat, getStaticInt, getStaticLong, getStaticObject, getStaticString, getString, getTraceLevel, getVmLibraryVersion, handleError, handleError, handleError, handleStaticError, handleStaticException, isDebug, isTrace, loadService, log, log, report, report, report, report, report, report, reportError, reportSystemInfo, setDebug, setDefaultLogService, setLogService, setTraceLevel, shouldLog, sleep, startupEscStatic, toStringConfigurationKeys, toStringInfo
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TraceConnection

public TraceConnection(ConnectionService connectionService)
Constructs an instance of this class from the specified connection service parameter. The connection service (ConnectionService) parameter.

Parameters:
connectionService - The connection service (ConnectionService) parameter.
Method Detail

close

public void close()
           throws java.io.IOException
Close.

Specified by:
close in interface ConnectionService
Overrides:
close in class Connection
Throws:
IOException.
java.io.IOException
See Also:
ConnectionService.close()

exit

public void exit()
          throws java.io.IOException
Exit.

Specified by:
exit in interface ConnectionService
Overrides:
exit in class Connection
Throws:
IOException.
java.io.IOException

flush

public void flush()
           throws java.io.IOException
Flush.

Specified by:
flush in interface ConnectionService
Overrides:
flush in class Connection
Throws:
IOException.
java.io.IOException

getConnectionService

public ConnectionService getConnectionService()
Gets the connection service value.

Returns:
The connection service (ConnectionService) value.
See Also:
setConnectionService(ConnectionService)

isOpen

public boolean isOpen()
Gets the open (boolean) value.

Specified by:
isOpen in interface ConnectionService
Overrides:
isOpen in class Connection
Returns:
The open (boolean) value.
See Also:
ConnectionService.isOpen(), Connection.setOpen(boolean)

open

public void open()
          throws java.io.IOException
Open.

Specified by:
open in interface ConnectionService
Overrides:
open in class Connection
Throws:
IOException.
java.io.IOException
See Also:
ConnectionService.open()

read

public int read(byte[] bytes)
         throws java.io.IOException
Read with the specified bytes parameter and return the int result. The bytes (byte[]) parameter.

Specified by:
read in interface ConnectionService
Overrides:
read in class Connection
Parameters:
bytes - The bytes (byte[]) parameter.
Returns:
Results of the read (int) value.
Throws:
IOException.
java.io.IOException
See Also:
read(byte[],int,int)

read

public int read(byte[] bytes,
                int offset,
                int length)
         throws java.io.IOException
Read with the specified bytes, offset and length parameters and return the int result. The bytes (byte[]) parameter. The offset (int) parameter. The length (int) parameter.

Specified by:
read in interface ConnectionService
Parameters:
bytes - The bytes (byte[]) parameter.
offset - The offset (int) parameter.
length - The length (int) parameter.
Returns:
Results of the read (int) value.
Throws:
IOException.
java.io.IOException
See Also:
read(byte[])

setConnectionService

public void setConnectionService(ConnectionService connectionService)
                          throws java.lang.IllegalArgumentException
Sets the connection service value. The connection service (ConnectionService) parameter. Illegal Argument Exception if connectionService is null.

Parameters:
connectionService - The connection service (ConnectionService) parameter.
Throws:
java.lang.IllegalArgumentException - Illegal Argument Exception.
See Also:
getConnectionService()

toString

public java.lang.String toString()
Returns the string value.

Overrides:
toString in class EscObject
Returns:
The string (String) value.
See Also:
EscObject.getStaticString(String,String), EscObject.getString(String,String)

write

public void write(byte[] bytes)
           throws java.io.IOException
Write with the specified bytes parameter. The bytes (byte[]) parameter.

Specified by:
write in interface ConnectionService
Overrides:
write in class Connection
Parameters:
bytes - The bytes (byte[]) parameter.
Throws:
IOException.
java.io.IOException
See Also:
write(byte[],int,int)

write

public void write(byte[] bytes,
                  int offset,
                  int count)
           throws java.io.IOException
Write with the specified bytes, offset and count parameters. The bytes (byte[]) parameter. The offset (int) parameter. The count (int) parameter.

Specified by:
write in interface ConnectionService
Parameters:
bytes - The bytes (byte[]) parameter.
offset - The offset (int) parameter.
count - The count (int) parameter.
Throws:
IOException.
java.io.IOException
See Also:
write(byte[])

1.0.0

Copyright (c) 1999, 2007 IBM