org.apache.camel.processor
Class Delayer

java.lang.Object
  extended by org.apache.camel.impl.ServiceSupport
      extended by org.apache.camel.processor.DelegateProcessor
          extended by org.apache.camel.processor.DelayProcessorSupport
              extended by org.apache.camel.processor.Delayer
All Implemented Interfaces:
Navigate, Processor, Traceable, Service

public class Delayer
extends DelayProcessorSupport
implements Traceable

A Delayer which delays processing the exchange until the correct amount of time has elapsed using an expression to determine the delivery time.

Version:
$Revision: 788621 $

Field Summary
 
Fields inherited from class org.apache.camel.processor.DelayProcessorSupport
log
 
Fields inherited from class org.apache.camel.processor.DelegateProcessor
processor
 
Constructor Summary
Delayer(Processor processor, Expression delay)
           
 
Method Summary
protected  long defaultProcessTime(Exchange exchange)
          A Strategy Method to allow derived implementations to decide the current system time or some other default exchange property
protected  void delay(Exchange exchange)
          Waits for an optional time period before continuing to process the exchange
 String getTraceLabel()
          Gets the trace label used for logging when tracing is enabled.
 String toString()
           
 
Methods inherited from class org.apache.camel.processor.DelayProcessorSupport
currentSystemTime, doStop, handleSleepInteruptedException, isFastStop, process, setFastStop, sleep, waitUntil
 
Methods inherited from class org.apache.camel.processor.DelegateProcessor
doStart, getProcessor, hasNext, next, proceed, processNext, setProcessor
 
Methods inherited from class org.apache.camel.impl.ServiceSupport
addChildService, getStatus, getVersion, isRunAllowed, isStarted, isStarting, isStopped, isStopping, removeChildService, start, stop
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Delayer

public Delayer(Processor processor,
               Expression delay)
Method Detail

toString

public String toString()
Overrides:
toString in class DelegateProcessor

getTraceLabel

public String getTraceLabel()
Description copied from interface: Traceable
Gets the trace label used for logging when tracing is enabled.

The lable should be short and precise.

Specified by:
getTraceLabel in interface Traceable
Returns:
the label

delay

protected void delay(Exchange exchange)
              throws Exception
Waits for an optional time period before continuing to process the exchange

Specified by:
delay in class DelayProcessorSupport
Throws:
Exception

defaultProcessTime

protected long defaultProcessTime(Exchange exchange)
A Strategy Method to allow derived implementations to decide the current system time or some other default exchange property



Apache CAMEL