net.gleamynode.netty.channel
Class AbstractChannel

java.lang.Object
  extended by net.gleamynode.netty.channel.AbstractChannel
All Implemented Interfaces:
Comparable<Channel>, Channel
Direct Known Subclasses:
AbstractServerChannel

public abstract class AbstractChannel
extends Object
implements Channel, Comparable<Channel>

Version:
$Rev$, $Date$
Author:
The Netty Project (netty@googlegroups.com), Trustin Lee (trustin@gmail.com)

Field Summary
 
Fields inherited from interface net.gleamynode.netty.channel.Channel
OP_NONE, OP_READ, OP_READ_WRITE, OP_WRITE
 
Constructor Summary
protected AbstractChannel(Channel parent, ChannelFactory factory, ChannelPipeline pipeline, ChannelSink sink)
           
 
Method Summary
 ChannelFuture bind(SocketAddress localAddress)
           
 ChannelFuture close()
           
 int compareTo(Channel o)
           
 ChannelFuture connect(SocketAddress remoteAddress)
           
 ChannelFuture disconnect()
           
 boolean equals(Object o)
           
 ChannelFactory getFactory()
           
 UUID getId()
           
 int getInterestOps()
           
 Channel getParent()
           
 ChannelPipeline getPipeline()
           
protected  ChannelFuture getSucceededFuture()
           
protected  ChannelFuture getUnsupportedOperationFuture()
           
 int hashCode()
           
 boolean isOpen()
           
 boolean isReadable()
           
 boolean isWritable()
           
protected  boolean setClosed()
           
 ChannelFuture setInterestOps(int interestOps)
           
protected  void setInterestOpsNow(int interestOps)
           
 ChannelFuture setReadable(boolean readable)
           
 String toString()
           
 ChannelFuture write(Object message)
           
 ChannelFuture write(Object message, SocketAddress remoteAddress)
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface net.gleamynode.netty.channel.Channel
getConfig, getLocalAddress, getRemoteAddress, isBound, isConnected
 

Constructor Detail

AbstractChannel

protected AbstractChannel(Channel parent,
                          ChannelFactory factory,
                          ChannelPipeline pipeline,
                          ChannelSink sink)
Method Detail

getId

public final UUID getId()
Specified by:
getId in interface Channel

getParent

public Channel getParent()
Specified by:
getParent in interface Channel

getFactory

public ChannelFactory getFactory()
Specified by:
getFactory in interface Channel

getPipeline

public ChannelPipeline getPipeline()
Specified by:
getPipeline in interface Channel

getSucceededFuture

protected ChannelFuture getSucceededFuture()

getUnsupportedOperationFuture

protected ChannelFuture getUnsupportedOperationFuture()

hashCode

public final int hashCode()
Overrides:
hashCode in class Object

equals

public final boolean equals(Object o)
Overrides:
equals in class Object

compareTo

public int compareTo(Channel o)
Specified by:
compareTo in interface Comparable<Channel>

isOpen

public boolean isOpen()
Specified by:
isOpen in interface Channel

setClosed

protected boolean setClosed()

bind

public ChannelFuture bind(SocketAddress localAddress)
Specified by:
bind in interface Channel

close

public ChannelFuture close()
Specified by:
close in interface Channel

connect

public ChannelFuture connect(SocketAddress remoteAddress)
Specified by:
connect in interface Channel

disconnect

public ChannelFuture disconnect()
Specified by:
disconnect in interface Channel

getInterestOps

public int getInterestOps()
Specified by:
getInterestOps in interface Channel

setInterestOps

public ChannelFuture setInterestOps(int interestOps)
Specified by:
setInterestOps in interface Channel

setInterestOpsNow

protected void setInterestOpsNow(int interestOps)

isReadable

public boolean isReadable()
Specified by:
isReadable in interface Channel

isWritable

public boolean isWritable()
Specified by:
isWritable in interface Channel

setReadable

public ChannelFuture setReadable(boolean readable)
Specified by:
setReadable in interface Channel

write

public ChannelFuture write(Object message)
Specified by:
write in interface Channel

write

public ChannelFuture write(Object message,
                           SocketAddress remoteAddress)
Specified by:
write in interface Channel

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2008-Present Trustin Heuiseung Lee. All Rights Reserved.