Class Policy
- java.lang.Object
-
- fish.payara.microprofile.faulttolerance.policy.Policy
-
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
AsynchronousPolicy,BulkheadPolicy,CircuitBreakerPolicy,FallbackPolicy,RetryPolicy,TimeoutPolicy
public abstract class Policy extends Object implements Serializable
Contains general helper method for FT policy validation.- Author:
- Jan Bernitt
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description Policy()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidcheckAtLeast(double minimum, Method annotatedMethod, Class<? extends Annotation> annotationType, String attribute, double value)static voidcheckAtLeast(long minimum, Method annotatedMethod, Class<? extends Annotation> annotationType, String attribute, long value)static voidcheckAtLeast(String attribute1, long minimum, Method annotatedMethod, Class<? extends Annotation> annotationType, String attribute2, long value)static voidcheckAtMost(double maximum, Method annotatedMethod, Class<? extends Annotation> annotationType, String attribute, double value)static voidcheckReturnsSameAs(Method annotatedMethod, Class<? extends Annotation> annotationType, String attribute, Class<?> valueType, String valueMethodName, Class<?>... valueParameterTypes)static voidcheckReturnsSameAs(Method annotatedMethod, Class<? extends Annotation> annotationType, String attribute, Method value)protected static Stringdescribe(Method annotatedMethod, Class<? extends Annotation> annotationType, String attribute)static booleanisCaught(Throwable ex, Class<? extends Throwable>[] caught)
-
-
-
Method Detail
-
checkAtLeast
public static void checkAtLeast(long minimum, Method annotatedMethod, Class<? extends Annotation> annotationType, String attribute, long value)
-
checkAtLeast
public static void checkAtLeast(double minimum, Method annotatedMethod, Class<? extends Annotation> annotationType, String attribute, double value)
-
checkAtLeast
public static void checkAtLeast(String attribute1, long minimum, Method annotatedMethod, Class<? extends Annotation> annotationType, String attribute2, long value)
-
checkAtMost
public static void checkAtMost(double maximum, Method annotatedMethod, Class<? extends Annotation> annotationType, String attribute, double value)
-
checkReturnsSameAs
public static void checkReturnsSameAs(Method annotatedMethod, Class<? extends Annotation> annotationType, String attribute, Class<?> valueType, String valueMethodName, Class<?>... valueParameterTypes)
-
checkReturnsSameAs
public static void checkReturnsSameAs(Method annotatedMethod, Class<? extends Annotation> annotationType, String attribute, Method value)
-
describe
protected static String describe(Method annotatedMethod, Class<? extends Annotation> annotationType, String attribute)
-
-