Class IfParamEquals
Object
AnchorBean<ChannelProvider>
InitializableBean<ChannelProvider, ImageInitialization>
ImageBean<ChannelProvider>
BeanProviderAsStackBase<ChannelProvider, Channel>
ChannelProvider
ChannelProviderUnary
IfParamEquals
- All Implemented Interfaces:
Provider<Channel>,ProviderAsStack
public class IfParamEquals
extends ChannelProviderUnary
Provides a channel based on a condition from a dictionary.
This class extends ChannelProviderUnary to return either the input channel or an
alternative channel based on a condition specified in a dictionary.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionChannelcreateFromChannel(Channel channel) ChannelProviderThe channel provider to use if the condition is false.The condition to evaluate from the dictionary.voidsetChannelElse(ChannelProvider channelElse) The channel provider to use if the condition is false.voidsetCondition(DictionaryCondition condition) The condition to evaluate from the dictionary.Methods inherited from class org.anchoranalysis.image.bean.provider.ChannelProviderUnary
get, getChannel, setChannelMethods inherited from class org.anchoranalysis.image.bean.provider.ChannelProvider
getAsStackMethods inherited from class org.anchoranalysis.bean.initializable.InitializableBean
getInitialization, getLogger, getPropertyInitializer, initialize, initializeRecursive, initRecursiveWithInitializer, isInitialized, onInitializationMethods inherited from class org.anchoranalysis.bean.AnchorBean
checkMisconfigured, describeBean, describeChildren, duplicateBean, fields, findFieldsOfClass, getBeanName, getLocalPath, localise, toString
-
Constructor Details
-
IfParamEquals
public IfParamEquals()
-
-
Method Details
-
createFromChannel
public Channel createFromChannel(Channel channel) throws ProvisionFailedException - Specified by:
createFromChannelin classChannelProviderUnary- Throws:
ProvisionFailedException
-
getCondition
The condition to evaluate from the dictionary. -
setCondition
The condition to evaluate from the dictionary. -
getChannelElse
public ChannelProvider getChannelElse()The channel provider to use if the condition is false. -
setChannelElse
public void setChannelElse(ChannelProvider channelElse) The channel provider to use if the condition is false.
-