org.opentox.toxotis.util
Class RetriableRequest<T>

java.lang.Object
  extended by org.opentox.toxotis.util.RetriableRequest<T>

public class RetriableRequest<T>
extends Object

An invocation that will be repeated after a certain time if it fails. The invocation is retried for a specified number of times.

Author:
Pantelis Sopasakis, Charalampos Chomenides

Constructor Summary
RetriableRequest(Method method, Object object)
           
 
Method Summary
 T retry(int maxRetries, long milliSecondsDelay)
           
 T retry(int maxRetries, long milliSecondsDelay, Object... methodParams)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RetriableRequest

public RetriableRequest(Method method,
                        Object object)
Method Detail

retry

public T retry(int maxRetries,
               long milliSecondsDelay,
               Object... methodParams)
        throws ToxOtisException
Throws:
ToxOtisException

retry

public T retry(int maxRetries,
               long milliSecondsDelay)
        throws ToxOtisException
Throws:
ToxOtisException


Copyright © 2011-2012 OpenTox. All Rights Reserved.