Package org.apache.camel.model
Class WhenDefinition
- All Implemented Interfaces:
org.apache.camel.CamelContextAware
,org.apache.camel.LineNumberAware
,Block
,CopyableDefinition<BasicOutputExpressionNode>
,DisabledAwareDefinition
,HasExpressionType
,OutputNode
,org.apache.camel.NamedNode
,org.apache.camel.spi.HasCamelContext
,org.apache.camel.spi.HasId
,org.apache.camel.spi.IdAware
@Metadata(label="eip,routing")
@AsPredicate
public class WhenDefinition
extends BasicOutputExpressionNode
implements DisabledAwareDefinition
Triggers a route when the expression evaluates to true
-
Constructor Summary
ConstructorsConstructorDescriptionWhenDefinition
(org.apache.camel.Expression expression) WhenDefinition
(ExpressionDefinition expression) WhenDefinition
(WhenDefinition source) WhenDefinition
(org.apache.camel.Predicate predicate) -
Method Summary
Modifier and TypeMethodDescriptionMakes a copy of this definition.protected String
Disables this EIP from the route during build time.getLabel()
void
setDisabled
(String disabled) Disables this EIP from the route during build time.void
Sets the id of this nodevoid
setParent
(ProcessorDefinition<?> parent) toString()
Methods inherited from class org.apache.camel.model.BasicOutputExpressionNode
addOutput, getOutputs, setOutputs
Methods inherited from class org.apache.camel.model.BasicExpressionNode
getExpression, getExpressionType, preCreateProcessor, setExpression, setExpression, setExpressionType
Methods inherited from class org.apache.camel.model.OptionalIdentifiedDefinition
description, getCamelContext, getCustomId, getDescription, getDescriptionText, getId, getLineNumber, getLocation, getNodePrefixId, hasCustomIdAssigned, id, idOrCreate, setCamelContext, setCustomId, setDescription, setGeneratedId, setLineNumber, setLocation
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.apache.camel.NamedNode
acceptDebugger
-
Constructor Details
-
WhenDefinition
public WhenDefinition() -
WhenDefinition
-
WhenDefinition
public WhenDefinition(org.apache.camel.Predicate predicate) -
WhenDefinition
public WhenDefinition(org.apache.camel.Expression expression) -
WhenDefinition
-
-
Method Details
-
getParent
- Specified by:
getParent
in interfaceorg.apache.camel.NamedNode
- Overrides:
getParent
in classOptionalIdentifiedDefinition<BasicOutputExpressionNode>
-
setParent
-
copyDefinition
Description copied from interface:CopyableDefinition
Makes a copy of this definition.- Specified by:
copyDefinition
in interfaceCopyableDefinition<BasicOutputExpressionNode>
-
toString
-
getShortName
- Specified by:
getShortName
in interfaceorg.apache.camel.NamedNode
-
getLabel
- Specified by:
getLabel
in interfaceorg.apache.camel.NamedNode
- Overrides:
getLabel
in classBasicExpressionNode<BasicOutputExpressionNode>
-
description
-
setId
Description copied from class:OptionalIdentifiedDefinition
Sets the id of this node- Specified by:
setId
in interfaceorg.apache.camel.spi.IdAware
- Overrides:
setId
in classOptionalIdentifiedDefinition<BasicOutputExpressionNode>
-
getDisabled
Description copied from interface:DisabledAwareDefinition
Disables this EIP from the route during build time. Once an EIP has been disabled then it cannot be enabled later at runtime.- Specified by:
getDisabled
in interfaceDisabledAwareDefinition
-
setDisabled
Description copied from interface:DisabledAwareDefinition
Disables this EIP from the route during build time. Once an EIP has been disabled then it cannot be enabled later at runtime.- Specified by:
setDisabled
in interfaceDisabledAwareDefinition
-