com.noelios.restlet.http
Class StreamClientHelper

java.lang.Object
  extended by org.restlet.util.Helper<T>
      extended by com.noelios.restlet.ConnectorHelper<Client>
          extended by com.noelios.restlet.ClientHelper
              extended by com.noelios.restlet.http.HttpClientHelper
                  extended by com.noelios.restlet.http.StreamClientHelper

public class StreamClientHelper
extends HttpClientHelper

HTTP client helper based on BIO sockets. Here is the list of parameters that are supported:

Parameter name Value type Default value Description
tcpNoDelay boolean false Indicate if Nagle's TCP_NODELAY algorithm should be used.

Author:
Jerome Louvel

Constructor Summary
StreamClientHelper(Client client)
          Constructor.
 
Method Summary
 HttpClientCall create(Request request)
          Creates a low-level HTTP client call from a high-level request.
 boolean getTcpNoDelay()
          Indicates if the protocol will use Nagle's algorithm
 void start()
           
 void stop()
           
 
Methods inherited from class com.noelios.restlet.http.HttpClientHelper
getConverter, handle, setConverter
 
Methods inherited from class com.noelios.restlet.ClientHelper
getConnectTimeout
 
Methods inherited from class com.noelios.restlet.ConnectorHelper
getProtocols, update
 
Methods inherited from class org.restlet.util.Helper
getAttributes, getContext, getHelped, getHelpedParameters, getLogger, setHelped
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StreamClientHelper

public StreamClientHelper(Client client)
Constructor.

Parameters:
client - The client to help.
Method Detail

create

public HttpClientCall create(Request request)
Description copied from class: HttpClientHelper
Creates a low-level HTTP client call from a high-level request.

Specified by:
create in class HttpClientHelper
Parameters:
request - The high-level request.
Returns:
A low-level HTTP client call.

getTcpNoDelay

public boolean getTcpNoDelay()
Indicates if the protocol will use Nagle's algorithm

Returns:
True to enable TCP_NODELAY, false to disable.
See Also:
Socket.setTcpNoDelay(boolean)

start

public void start()
           throws java.lang.Exception
Overrides:
start in class ConnectorHelper<Client>
Throws:
java.lang.Exception

stop

public void stop()
          throws java.lang.Exception
Overrides:
stop in class ConnectorHelper<Client>
Throws:
java.lang.Exception


Copyright © 2005-2008 Noelios Technologies.