@Retention(value=RUNTIME)
@Target(value={TYPE,METHOD})
@Conditional(value=OnPropertyCondition.class)
public @interface ConditionalOnProperty
| Modifier and Type | Required Element and Description |
|---|---|
boolean |
enableIfMissing
Should the bean be created if property is missing?
|
java.lang.String |
value
The name of the boolean property that activate the target class
|
| Modifier and Type | Optional Element and Description |
|---|---|
boolean |
havingValue
for this condition to match, the value of the property must be equal to havingValue()
|