org.jppf.server.nio
Class ChannelWrapper<S>

java.lang.Object
  extended by org.jppf.server.nio.ChannelWrapper<S>
Type Parameters:
S - the type of wrapped channel.

public class ChannelWrapper<S>
extends Object

Wraps a communication channel, no matter what the channel is.

Author:
Laurent Cohen

Constructor Summary
ChannelWrapper(S channel)
          Initialize this channel wrapper with the specified channel.
 
Method Summary
 boolean equals(Object obj)
          Determine whether an other object is equal to this one.
 S getChannel()
          Get the channel to wrap.
 int hashCode()
          Get the hashcode for this object.
 String toString()
          Generate a string that represents this channel wrapper.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ChannelWrapper

public ChannelWrapper(S channel)
Initialize this channel wrapper with the specified channel.

Parameters:
channel - the channel to wrap.
Method Detail

getChannel

public S getChannel()
Get the channel to wrap.

Returns:
the wrapped channel.

hashCode

public int hashCode()
Get the hashcode for this object.

Overrides:
hashCode in class Object
Returns:
the hashcode of the wrapped channel.
See Also:
Object.hashCode()

equals

public boolean equals(Object obj)
Determine whether an other object is equal to this one.

Overrides:
equals in class Object
Parameters:
obj - the object to compare with.
Returns:
true if this object is equal to the other one, false otherwise.
See Also:
Object.equals(java.lang.Object)

toString

public String toString()
Generate a string that represents this channel wrapper.

Overrides:
toString in class Object
Returns:
a string that represents this channel wrapper.
See Also:
Object.toString()


Copyright © 2005-2010 JPPF Team.