Added Conditional#negated

This commit is contained in:
Rsl1122 2019-03-24 15:34:58 +02:00
parent 2b620f97f1
commit 600e90873e

View File

@ -41,4 +41,14 @@ public @interface Conditional {
*/
String value();
}
/**
* Reverse the condition.
* <p>
* Example:
* - Method with {@code Conditional("expires", negated = true)} will only be called when the condition "expires" is false.
*
* @return {@code false} by default.
*/
boolean negated() default false;
}