Class ProcessDefinition

All Implemented Interfaces:
org.apache.camel.CamelContextAware, org.apache.camel.LineNumberAware, Block, CopyableDefinition<ProcessorDefinition>, DisabledAwareDefinition, org.apache.camel.NamedNode, org.apache.camel.spi.HasCamelContext, org.apache.camel.spi.HasId, org.apache.camel.spi.IdAware

@Metadata(label="eip,endpoint") public class ProcessDefinition extends NoOutputDefinition<ProcessDefinition>
Calls a Camel processor
  • Constructor Details

    • ProcessDefinition

      public ProcessDefinition()
    • ProcessDefinition

      protected ProcessDefinition(ProcessDefinition source)
    • ProcessDefinition

      public ProcessDefinition(org.apache.camel.Processor processor)
  • Method Details

    • copyDefinition

      public ProcessDefinition copyDefinition()
      Description copied from interface: CopyableDefinition
      Makes a copy of this definition.
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • getShortName

      public String getShortName()
    • getLabel

      public String getLabel()
      Description copied from class: ProcessorDefinition
      Returns a label to describe this node such as the expression if some kind of expression node
      Specified by:
      getLabel in interface org.apache.camel.NamedNode
      Overrides:
      getLabel in class ProcessorDefinition<ProcessDefinition>
    • getProcessor

      public org.apache.camel.Processor getProcessor()
    • getRef

      public String getRef()
    • setRef

      public void setRef(String ref)
      Reference to the Processor to lookup in the registry to use. A Processor is a class of type org.apache.camel.Processor, which can are to be called by this EIP. In this processor you have custom Java code, that can work with the message, such as to do custom business logic, special message manipulations and so on. By default, the ref, will lookup the bean in the Camel registry. The ref can use prefix that controls how the processor is obtained. You can use #bean:myBean where myBean is the id of the Camel processor (lookup). Can also be used for creating new beans by their class name by prefixing with #class, eg #class:com.foo.MyClassType. And it is also possible to refer to singleton beans by their type in the registry by prefixing with #type: syntax, eg #type:com.foo.MyClassType