org.apache.camel.component.pojo.timer
Class TimerEndpoint

java.lang.Object
  extended by org.apache.camel.impl.DefaultEndpoint<PojoExchange>
      extended by org.apache.camel.component.pojo.timer.TimerEndpoint
All Implemented Interfaces:
Endpoint<PojoExchange>

public class TimerEndpoint
extends DefaultEndpoint<PojoExchange>

Represents a timer endpoint that can generate periodic inbound PojoExchanges.

Version:
$Revision: 519973 $

Constructor Summary
TimerEndpoint(String fullURI, TimerComponent component, String timerPartURI)
           
 
Method Summary
 Consumer<PojoExchange> createConsumer(Processor processor)
          Creates a new Event Driven Consumer which consumes messages from the endpoint using the given processor
 PojoExchange createExchange()
          Create a new exchange for communicating with this endpoint
 Producer<PojoExchange> createProducer()
          Creates a new producer which is used send messages into the endpoint
 TimerComponent getComponent()
           
 long getDelay()
           
 long getPeriod()
           
 Date getTime()
           
 String getTimerName()
           
 boolean isDaemon()
           
 boolean isFixedRate()
           
 boolean isSingleton()
          Returns if the endpoint should be a CamelContext singleton.
 void setDaemon(boolean daemon)
           
 void setDelay(long delay)
           
 void setFixedRate(boolean fixedRate)
           
 void setPeriod(long period)
           
 void setTime(Date time)
           
 
Methods inherited from class org.apache.camel.impl.DefaultEndpoint
convertTo, createExchange, createExecutorService, createPollingConsumer, equals, getContext, getEndpointUri, getExchangeType, getExecutorService, hashCode, setExecutorService, toExchangeType, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TimerEndpoint

public TimerEndpoint(String fullURI,
                     TimerComponent component,
                     String timerPartURI)
              throws URISyntaxException
Throws:
URISyntaxException
Method Detail

createProducer

public Producer<PojoExchange> createProducer()
                                      throws Exception
Description copied from interface: Endpoint
Creates a new producer which is used send messages into the endpoint

Returns:
a newly created producer
Throws:
Exception

createConsumer

public Consumer<PojoExchange> createConsumer(Processor processor)
                                      throws Exception
Description copied from interface: Endpoint
Creates a new Event Driven Consumer which consumes messages from the endpoint using the given processor

Returns:
a newly created consumer
Throws:
Exception

createExchange

public PojoExchange createExchange()
Description copied from interface: Endpoint
Create a new exchange for communicating with this endpoint


getComponent

public TimerComponent getComponent()
Overrides:
getComponent in class DefaultEndpoint<PojoExchange>

getTimerName

public String getTimerName()

isDaemon

public boolean isDaemon()

setDaemon

public void setDaemon(boolean daemon)

getDelay

public long getDelay()

setDelay

public void setDelay(long delay)

isFixedRate

public boolean isFixedRate()

setFixedRate

public void setFixedRate(boolean fixedRate)

getPeriod

public long getPeriod()

setPeriod

public void setPeriod(long period)

getTime

public Date getTime()

setTime

public void setTime(Date time)

isSingleton

public boolean isSingleton()
Description copied from interface: Endpoint
Returns if the endpoint should be a CamelContext singleton. If the endpoint is a Singleton, then a single Endpoint instance will be shared by all routes with the same URI. Because the endpoint is shared, it should be treated as an immutable.



Copyright © 2007 Apache Software Foundation. All Rights Reserved.