org.apache.http.impl.nio.reactor
Class SessionRequestImpl

java.lang.Object
  extended by org.apache.http.impl.nio.reactor.SessionRequestImpl
All Implemented Interfaces:
SessionRequest

public class SessionRequestImpl
extends java.lang.Object
implements SessionRequest


Constructor Summary
SessionRequestImpl(java.net.SocketAddress remoteAddress, java.net.SocketAddress localAddress, java.lang.Object attachment, SessionRequestCallback callback)
           
 
Method Summary
 void cancel()
           
 void completed(IOSession session)
           
 void failed(java.io.IOException exception)
           
 java.lang.Object getAttachment()
           
 int getConnectTimeout()
           
 java.io.IOException getException()
           
 java.net.SocketAddress getLocalAddress()
           
 java.net.SocketAddress getRemoteAddress()
           
 IOSession getSession()
           
 boolean isCompleted()
           
 void setConnectTimeout(int timeout)
           
protected  void setKey(java.nio.channels.SelectionKey key)
           
 void timeout()
           
 void waitFor()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SessionRequestImpl

public SessionRequestImpl(java.net.SocketAddress remoteAddress,
                          java.net.SocketAddress localAddress,
                          java.lang.Object attachment,
                          SessionRequestCallback callback)
Method Detail

getRemoteAddress

public java.net.SocketAddress getRemoteAddress()
Specified by:
getRemoteAddress in interface SessionRequest

getLocalAddress

public java.net.SocketAddress getLocalAddress()
Specified by:
getLocalAddress in interface SessionRequest

getAttachment

public java.lang.Object getAttachment()
Specified by:
getAttachment in interface SessionRequest

isCompleted

public boolean isCompleted()
Specified by:
isCompleted in interface SessionRequest

waitFor

public void waitFor()
             throws java.lang.InterruptedException
Specified by:
waitFor in interface SessionRequest
Throws:
java.lang.InterruptedException

getSession

public IOSession getSession()
Specified by:
getSession in interface SessionRequest

getException

public java.io.IOException getException()
Specified by:
getException in interface SessionRequest

completed

public void completed(IOSession session)

failed

public void failed(java.io.IOException exception)

timeout

public void timeout()

getConnectTimeout

public int getConnectTimeout()
Specified by:
getConnectTimeout in interface SessionRequest

setConnectTimeout

public void setConnectTimeout(int timeout)
Specified by:
setConnectTimeout in interface SessionRequest

setKey

protected void setKey(java.nio.channels.SelectionKey key)

cancel

public void cancel()
Specified by:
cancel in interface SessionRequest


Copyright © 2005-2009 Apache Software Foundation. All Rights Reserved.