org.apache.commons.httpclient
Class DefaultMethodRetryHandler

java.lang.Object
  extended by org.apache.commons.httpclient.DefaultMethodRetryHandler
All Implemented Interfaces:
MethodRetryHandler

Deprecated. use DefaultHttpMethodRetryHandler

public class DefaultMethodRetryHandler
extends Object
implements MethodRetryHandler

The default MethodRetryHandler used by HttpMethodBase.

Author:
Michael Becke
See Also:
HttpMethodBase.setMethodRetryHandler(MethodRetryHandler)

Constructor Summary
DefaultMethodRetryHandler()
          Deprecated.  
 
Method Summary
 int getRetryCount()
          Deprecated.  
 boolean isRequestSentRetryEnabled()
          Deprecated.  
 boolean retryMethod(HttpMethod method, HttpConnection connection, HttpRecoverableException recoverableException, int executionCount, boolean requestSent)
          Deprecated. Used retryCount and requestSentRetryEnabled to determine if the given method should be retried.
 void setRequestSentRetryEnabled(boolean requestSentRetryEnabled)
          Deprecated.  
 void setRetryCount(int retryCount)
          Deprecated.  
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultMethodRetryHandler

public DefaultMethodRetryHandler()
Deprecated. 
Method Detail

retryMethod

public boolean retryMethod(HttpMethod method,
                           HttpConnection connection,
                           HttpRecoverableException recoverableException,
                           int executionCount,
                           boolean requestSent)
Deprecated. 
Used retryCount and requestSentRetryEnabled to determine if the given method should be retried.

Specified by:
retryMethod in interface MethodRetryHandler
Parameters:
method - the method being executed
connection - the connection the method is using
recoverableException - the exception that occurred
executionCount - the number of times this method has been unsuccessfully executed
requestSent - this argument is unused and will be removed in the future. HttpMethod.isRequestSent() should be used instead
Returns:
true if the method should be retried, false otherwise
See Also:
MethodRetryHandler.retryMethod(HttpMethod, HttpConnection, HttpRecoverableException, int, boolean)

isRequestSentRetryEnabled

public boolean isRequestSentRetryEnabled()
Deprecated. 
Returns:
true if this handler will retry methods that have successfully sent their request, false otherwise

getRetryCount

public int getRetryCount()
Deprecated. 
Returns:
the maximum number of times a method will be retried

setRequestSentRetryEnabled

public void setRequestSentRetryEnabled(boolean requestSentRetryEnabled)
Deprecated. 
Parameters:
requestSentRetryEnabled - a flag indicating if methods that have successfully sent their request should be retried

setRetryCount

public void setRetryCount(int retryCount)
Deprecated. 
Parameters:
retryCount - the maximum number of times a method can be retried


Copyright © 2001-2008 Apache Software Foundation. All Rights Reserved.