Class ConfigConditionalContext<T>
- java.lang.Object
-
- io.streamthoughts.azkarra.runtime.components.condition.ConfigConditionalContext<T>
-
- All Implemented Interfaces:
ComponentConditionalContext<ComponentDescriptor<T>>
public class ConfigConditionalContext<T> extends Object implements ComponentConditionalContext<ComponentDescriptor<T>>
DefaultComponentConditionalContext
implementation..
-
-
Constructor Summary
Constructors Constructor Description ConfigConditionalContext(Conf config)
Creates a newConfigConditionalContext
instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
isEnable(ComponentFactory factory, ComponentDescriptor<T> descriptor)
Verify if this component is enabled for the given context.
-
-
-
Constructor Detail
-
ConfigConditionalContext
public ConfigConditionalContext(Conf config)
Creates a newConfigConditionalContext
instance.- Parameters:
config
- theConf
.
-
-
Method Detail
-
isEnable
public boolean isEnable(ComponentFactory factory, ComponentDescriptor<T> descriptor)
Verify if this component is enabled for the given context.- Specified by:
isEnable
in interfaceComponentConditionalContext<T>
- Parameters:
factory
- theComponentFactory
; cannot benull
.descriptor
- theComponentDescriptor
; cannot benull
.- Returns:
true
if the compoenent is enable.
-
-