org.openorb.orb.net
Class NullSocketStreamDecorationStrategy

java.lang.Object
  extended by org.openorb.orb.net.NullSocketStreamDecorationStrategy
All Implemented Interfaces:
SocketStreamDecorationStrategy

public final class NullSocketStreamDecorationStrategy
extends java.lang.Object
implements SocketStreamDecorationStrategy

A stretegy that does nothing.

Version:
$Revision: 1.1 $ $Date: 2004/05/17 08:23:00 $
Author:
Richard G Clark

Nested Class Summary
 
Nested classes/interfaces inherited from interface org.openorb.orb.net.SocketStreamDecorationStrategy
SocketStreamDecorationStrategy.Factory
 
Method Summary
 java.io.InputStream decorate(java.net.Socket socket, java.io.InputStream stream)
          Returns the passed stream without modifcation.
 java.io.OutputStream decorate(java.net.Socket socket, java.io.OutputStream stream)
          Returns the passed stream without midifcation.
static NullSocketStreamDecorationStrategy getInstance()
          Returns the singleton instance of this class.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getInstance

public static NullSocketStreamDecorationStrategy getInstance()
Returns the singleton instance of this class.

Returns:
the singleton instance

decorate

public java.io.InputStream decorate(java.net.Socket socket,
                                    java.io.InputStream stream)
                             throws java.io.IOException
Returns the passed stream without modifcation.

Specified by:
decorate in interface SocketStreamDecorationStrategy
Parameters:
socket - the source of the original stream
stream - the stream to be decorated
Returns:
a decorated InputStream.
Throws:
java.io.IOException - if an I/O error occurs while creating the socket.

decorate

public java.io.OutputStream decorate(java.net.Socket socket,
                                     java.io.OutputStream stream)
                              throws java.io.IOException
Returns the passed stream without midifcation.

Specified by:
decorate in interface SocketStreamDecorationStrategy
Parameters:
socket - the source of the original stream
stream - the stream to be decorated
Returns:
a decorated OutputStream.
Throws:
java.io.IOException - if an I/O error occurs while creating the socket.