org.apache.geronimo.network.protocol
Class SocketProtocol
java.lang.Object
org.apache.geronimo.network.protocol.SocketProtocol
- All Implemented Interfaces:
- AcceptableProtocol, Cloneable, Protocol, SelectionEventListner, ServerSocketAcceptorListener
- public class SocketProtocol
- extends Object
- implements AcceptableProtocol, SelectionEventListner
- Version:
- $Revision: 1.16 $ $Date: 2004/08/02 03:53:30 $
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SocketProtocol
public SocketProtocol()
getUpProtocol
public Protocol getUpProtocol()
- Specified by:
getUpProtocol
in interface Protocol
setUpProtocol
public void setUpProtocol(Protocol up)
- Specified by:
setUpProtocol
in interface Protocol
getDownProtocol
public Protocol getDownProtocol()
- Specified by:
getDownProtocol
in interface Protocol
setDownProtocol
public void setDownProtocol(Protocol down)
- Specified by:
setDownProtocol
in interface Protocol
clearLinks
public void clearLinks()
- Specified by:
clearLinks
in interface Protocol
getSocketChannel
public SocketChannel getSocketChannel()
setSocketChannel
public void setSocketChannel(SocketChannel socketChannel)
getAddress
public SocketAddress getAddress()
setAddress
public void setAddress(SocketAddress address)
getInterface
public SocketAddress getInterface()
setInterface
public void setInterface(SocketAddress socketInterface)
getTimeout
public long getTimeout()
setTimeout
public void setTimeout(long timeout)
isTCPNoDelay
public boolean isTCPNoDelay()
setTCPNoDelay
public void setTCPNoDelay(boolean TCPNoDelay)
isReuseAddress
public boolean isReuseAddress()
setReuseAddress
public void setReuseAddress(boolean reuseAddress)
getSelectorManager
public SelectorManager getSelectorManager()
setSelectorManager
public void setSelectorManager(SelectorManager selectorManager)
isDone
public boolean isDone()
- Specified by:
isDone
in interface AcceptableProtocol
getCreated
public long getCreated()
- Specified by:
getCreated
in interface AcceptableProtocol
getLastUsed
public long getLastUsed()
- Specified by:
getLastUsed
in interface AcceptableProtocol
cloneProtocol
public Protocol cloneProtocol()
throws CloneNotSupportedException
- Specified by:
cloneProtocol
in interface Protocol
- Throws:
CloneNotSupportedException
setup
public void setup()
throws ProtocolException
- Specified by:
setup
in interface Protocol
- Throws:
ProtocolException
drain
public void drain()
throws ProtocolException
- Specified by:
drain
in interface Protocol
- Throws:
ProtocolException
teardown
public void teardown()
throws ProtocolException
- Specified by:
teardown
in interface Protocol
- Throws:
ProtocolException
sendUp
public void sendUp(UpPacket packet)
throws ProtocolException
- Specified by:
sendUp
in interface Protocol
- Throws:
ProtocolException
sendDown
public void sendDown(DownPacket packet)
throws ProtocolException
- Specified by:
sendDown
in interface Protocol
- Throws:
ProtocolException
flush
public void flush()
throws ProtocolException
- Specified by:
flush
in interface Protocol
- Throws:
ProtocolException
selectionEvent
public void selectionEvent(SelectorManager.Event event)
- Description copied from interface:
SelectionEventListner
- When the SelectorKey is triggered, the service method will
be called on the attachment.
- Specified by:
selectionEvent
in interface SelectionEventListner
serviceRead
public void serviceRead()
close
public void close()
accept
public void accept(SocketChannel socketChannel)
- Specified by:
accept
in interface ServerSocketAcceptorListener
Copyright © 2003-2005 Apache Software Foundation. All Rights Reserved.