org.jboss.remoting.socketfactory
Class CreationListenerSocketFactory

java.lang.Object
  extended by javax.net.SocketFactory
      extended by javax.net.ssl.SSLSocketFactory
          extended by org.jboss.remoting.socketfactory.CreationListenerSocketFactory
All Implemented Interfaces:
java.io.Serializable, SocketFactoryWrapper

public class CreationListenerSocketFactory
extends javax.net.ssl.SSLSocketFactory
implements SocketFactoryWrapper, java.io.Serializable

A CreationListenerSocketFactory wraps a SocketFactory and notifies a listener of the creation of a Socket before returning the socket.

Version:
$Revision: 1866 $

Copyright Jan 10, 2007

Author:
Ron Sigal
See Also:
Serialized Form

Constructor Summary
CreationListenerSocketFactory(SocketCreationListener listener)
           
CreationListenerSocketFactory(javax.net.SocketFactory factory, SocketCreationListener listener)
           
 
Method Summary
protected  void checkFactory()
           
 java.net.Socket createSocket()
           
 java.net.Socket createSocket(java.net.InetAddress host, int port)
           
 java.net.Socket createSocket(java.net.InetAddress address, int port, java.net.InetAddress clientAddress, int clientPort)
           
 java.net.Socket createSocket(java.net.Socket s, java.lang.String host, int port, boolean autoClose)
           
 java.net.Socket createSocket(java.lang.String host, int port)
           
 java.net.Socket createSocket(java.lang.String host, int port, java.net.InetAddress clientHost, int clientPort)
           
 java.lang.String[] getDefaultCipherSuites()
           
 javax.net.SocketFactory getFactory()
           
 SocketCreationListener getListener()
           
 javax.net.SocketFactory getSocketFactory()
           
 java.lang.String[] getSupportedCipherSuites()
           
 void setFactory(javax.net.SocketFactory factory)
           
 void setListener(SocketCreationListener listener)
           
 void setSocketFactory(javax.net.SocketFactory factory)
           
 
Methods inherited from class javax.net.ssl.SSLSocketFactory
getDefault
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CreationListenerSocketFactory

public CreationListenerSocketFactory(SocketCreationListener listener)

CreationListenerSocketFactory

public CreationListenerSocketFactory(javax.net.SocketFactory factory,
                                     SocketCreationListener listener)
Method Detail

getFactory

public javax.net.SocketFactory getFactory()

getListener

public SocketCreationListener getListener()

setFactory

public void setFactory(javax.net.SocketFactory factory)

setListener

public void setListener(SocketCreationListener listener)

createSocket

public java.net.Socket createSocket()
                             throws java.io.IOException
Overrides:
createSocket in class javax.net.SocketFactory
Throws:
java.io.IOException

createSocket

public java.net.Socket createSocket(java.lang.String host,
                                    int port)
                             throws java.io.IOException,
                                    java.net.UnknownHostException
Specified by:
createSocket in class javax.net.SocketFactory
Throws:
java.io.IOException
java.net.UnknownHostException

createSocket

public java.net.Socket createSocket(java.lang.String host,
                                    int port,
                                    java.net.InetAddress clientHost,
                                    int clientPort)
                             throws java.io.IOException,
                                    java.net.UnknownHostException
Specified by:
createSocket in class javax.net.SocketFactory
Throws:
java.io.IOException
java.net.UnknownHostException

createSocket

public java.net.Socket createSocket(java.net.InetAddress host,
                                    int port)
                             throws java.io.IOException
Specified by:
createSocket in class javax.net.SocketFactory
Throws:
java.io.IOException

createSocket

public java.net.Socket createSocket(java.net.InetAddress address,
                                    int port,
                                    java.net.InetAddress clientAddress,
                                    int clientPort)
                             throws java.io.IOException
Specified by:
createSocket in class javax.net.SocketFactory
Throws:
java.io.IOException

getDefaultCipherSuites

public java.lang.String[] getDefaultCipherSuites()
Specified by:
getDefaultCipherSuites in class javax.net.ssl.SSLSocketFactory

getSupportedCipherSuites

public java.lang.String[] getSupportedCipherSuites()
Specified by:
getSupportedCipherSuites in class javax.net.ssl.SSLSocketFactory

createSocket

public java.net.Socket createSocket(java.net.Socket s,
                                    java.lang.String host,
                                    int port,
                                    boolean autoClose)
                             throws java.io.IOException
Specified by:
createSocket in class javax.net.ssl.SSLSocketFactory
Throws:
java.io.IOException

getSocketFactory

public javax.net.SocketFactory getSocketFactory()
Specified by:
getSocketFactory in interface SocketFactoryWrapper

setSocketFactory

public void setSocketFactory(javax.net.SocketFactory factory)
Specified by:
setSocketFactory in interface SocketFactoryWrapper

checkFactory

protected void checkFactory()


Copyright © 1998-2005 JBoss Inc . All Rights Reserved.