ConditionalOnBean class
Register bean only if a bean of the specified type exists
Example:
@Service()
@ConditionalOnBean(DatabaseService)
class UserCacheService {
// Only registered if DatabaseService bean exists
}
- Inheritance
-
- Object
- Conditional
- ConditionalOnBean
Constructors
- ConditionalOnBean(Type type, {String? qualifier})
-
const
Properties
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited