Tidy up some javadocs

This commit is contained in:
Dave Syer
2016-02-10 09:34:06 +00:00
parent d0ac53c76e
commit c1ad693825
2 changed files with 13 additions and 10 deletions

View File

@@ -19,7 +19,10 @@ package org.springframework.retry;
/**
* Callback interface for an operation that can be retried using a
* {@link RetryOperations}.
*
*
* @param T the type of object returned by the callback
* @param E the type of exception it declares may be thrown
*
* @author Rob Harrop
* @author Dave Syer
*/
@@ -31,7 +34,7 @@ public interface RetryCallback<T, E extends Throwable> {
* semantics when an operation is retried.
* @param context the current retry context.
* @return the result of the successful operation.
* @throws Exception if processing fails
* @throws Throwable of type E if processing fails
*/
T doWithRetry(RetryContext context) throws E;
}

View File

@@ -23,9 +23,9 @@ package org.springframework.retry;
* framework, e.g. to support nested retries. Context can also be external, and
* the {@link RetryPolicy} provides a uniform API for a range of different
* platforms for the external context.
*
*
* @author Dave Syer
*
*
*/
public interface RetryPolicy {
@@ -40,23 +40,23 @@ public interface RetryPolicy {
* in so that marker interfaces can be used and a manager can collaborate
* with the callback to set up some state in the status token.
* @param parent the parent context if we are in a nested retry.
*
* @return a {@link RetryContext} object specific to this manager.
*
*
* @return a {@link RetryContext} object specific to this policy.
*
*/
RetryContext open(RetryContext parent);
/**
* @param context a retry status created by the
* {@link #open(RetryContext)} method of this manager.
* {@link #open(RetryContext)} method of this policy.
*/
void close(RetryContext context);
/**
* Called once per retry attempt, after the callback fails.
*
*
* @param context the current status object.
*
*
*/
void registerThrowable(RetryContext context, Throwable throwable);