org.jacorb.orb.iiop
Class IIOPConnection

java.lang.Object
  extended by org.omg.CORBA.LocalObject
      extended by org.omg.ETF._ConnectionLocalBase
          extended by org.jacorb.orb.etf.ConnectionBase
              extended by org.jacorb.orb.etf.StreamConnectionBase
                  extended by org.jacorb.orb.iiop.IIOPConnection
All Implemented Interfaces:
java.io.Serializable, org.jacorb.config.Configurable, LocalInterface, Object, IDLEntity, Connection, ConnectionOperations
Direct Known Subclasses:
ClientIIOPConnection, ServerIIOPConnection

public abstract class IIOPConnection
extends StreamConnectionBase

Version:
$Id: IIOPConnection.java,v 1.18 2009-03-27 12:13:57 alexander.bykov Exp $
Author:
Nicolas Noffke, Andre Spiegel
See Also:
Serialized Form

Field Summary
protected  java.net.Socket socket
           
protected  boolean use_ssl
           
 
Fields inherited from class org.jacorb.orb.etf.StreamConnectionBase
in_stream, out_stream
 
Fields inherited from class org.jacorb.orb.etf.ConnectionBase
b_out, configuration, connected, connection_info, finalTimeout, logger, orb, profile
 
Constructor Summary
IIOPConnection()
           
 
Method Summary
 java.net.Socket getSocket()
           
protected  int getTimeout()
           
protected  COMM_FAILURE handleCommFailure(java.io.IOException e)
          this is invoked whenever a communication error occurs.
 int hashCode()
          hashCode returns the hash code value for the object.
 boolean isSSL()
           
protected  void setTimeout(int timeout)
           
 
Methods inherited from class org.jacorb.orb.etf.StreamConnectionBase
flush, is_data_available, read, write
 
Methods inherited from class org.jacorb.orb.etf.ConnectionBase
configure, get_server_profile, getLocalhost, is_connected, supports_callback, to_COMM_FAILURE, turnOnFinalTimeout, use_handle_time_out, wait_next_data
 
Methods inherited from class org.omg.ETF._ConnectionLocalBase
_ids
 
Methods inherited from class org.omg.CORBA.LocalObject
_create_request, _create_request, _duplicate, _get_component, _get_domain_managers, _get_interface_def, _get_interface, _get_policy, _hash, _invoke, _is_a, _is_equivalent, _is_local, _non_existent, _orb, _release, _releaseReply, _request, _request, _servant_postinvoke, _servant_preinvoke, _set_policy_override, validate_connection
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.omg.ETF.ConnectionOperations
close, connect
 
Methods inherited from interface org.omg.CORBA.Object
_create_request, _create_request, _duplicate, _get_component, _get_domain_managers, _get_interface_def, _get_interface, _get_policy, _hash, _is_a, _is_equivalent, _non_existent, _release, _request, _set_policy_override
 

Field Detail

socket

protected java.net.Socket socket

use_ssl

protected boolean use_ssl
Constructor Detail

IIOPConnection

public IIOPConnection()
Method Detail

isSSL

public boolean isSSL()

setTimeout

protected void setTimeout(int timeout)
Specified by:
setTimeout in class ConnectionBase

handleCommFailure

protected COMM_FAILURE handleCommFailure(java.io.IOException e)
Description copied from class: ConnectionBase
this is invoked whenever a communication error occurs. subclasses must provide a appropiate implementation. the simplest possible implementation would just pass in the specified exception to to_COMM_FAILURE and return the result.

Specified by:
handleCommFailure in class ConnectionBase

getTimeout

protected int getTimeout()
Specified by:
getTimeout in class ConnectionBase

hashCode

public int hashCode()
hashCode returns the hash code value for the object. It will return the hashCode of the underlying socket. If the socket is null or closed it will return hash of the IIOPConnection itself. Note - if this is changed this may break the context minikey system.

Overrides:
hashCode in class java.lang.Object
Returns:
an int value

getSocket

public java.net.Socket getSocket()