Package co.verisoft.fw.utils
Interface Attemptable
public interface Attemptable
Attempt interface, to use in Retry object. Mostly used as anonymous class
- Since:
- 1.9.6 (2019)
- Author:
- Nir Gallner @ www.VeriSoft.co
-
Method Summary
Modifier and TypeMethodDescriptionvoid
attempt()
Attempt - the actual action to be performed.void
Activated when the attempt method fails
-
Method Details
-
attempt
Attempt - the actual action to be performed. Try to perform a small as possible action to avoid recursive attempt. Compose the attempt method to throw an Error or Exception (Throwable object) if the attempt fails.- Throws:
Throwable
- an object to throw if the attempt method did not succeed.
-
onAttemptFail
void onAttemptFail()Activated when the attempt method fails
-