org.apache.camel.component.cometd
Class CometdProducer

java.lang.Object
  extended by org.apache.camel.impl.ServiceSupport
      extended by org.apache.camel.impl.DefaultProducer
          extended by org.apache.camel.component.cometd.CometdProducer
All Implemented Interfaces:
CometdProducerConsumer, IsSingleton, Processor, Producer, Service, ShutdownableService

public class CometdProducer
extends DefaultProducer
implements CometdProducerConsumer

A Producer to send messages using Cometd and Bayeux protocol.

Version:

Field Summary
 
Fields inherited from class org.apache.camel.impl.DefaultProducer
log
 
Constructor Summary
CometdProducer(CometdEndpoint endpoint)
           
 
Method Summary
 org.cometd.server.AbstractBayeux getBayeux()
           
 CometdEndpoint getEndpoint()
          Gets the endpoint this producer sends to.
 void process(Exchange exchange)
          Processes the message exchange
 void setBayeux(org.cometd.server.AbstractBayeux bayeux)
          Sets the bayeux to use.
 void start()
          Starts the service
 void stop()
          Stops the service
 
Methods inherited from class org.apache.camel.impl.DefaultProducer
createExchange, createExchange, createExchange, doStart, doStop, isSingleton, toString
 
Methods inherited from class org.apache.camel.impl.ServiceSupport
addChildService, doResume, doShutdown, doSuspend, getStatus, getVersion, isRunAllowed, isStarted, isStarting, isStopped, isStopping, isSuspended, isSuspending, removeChildService, resume, shutdown, start, suspend
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CometdProducer

public CometdProducer(CometdEndpoint endpoint)
Method Detail

start

public void start()
           throws Exception
Description copied from interface: Service
Starts the service

Specified by:
start in interface Service
Overrides:
start in class ServiceSupport
Throws:
Exception - is thrown if starting failed

stop

public void stop()
          throws Exception
Description copied from interface: Service
Stops the service

Specified by:
stop in interface Service
Overrides:
stop in class ServiceSupport
Throws:
Exception - is thrown if stopping failed

process

public void process(Exchange exchange)
Description copied from interface: Processor
Processes the message exchange

Specified by:
process in interface Processor
Parameters:
exchange - the message exchange

getEndpoint

public CometdEndpoint getEndpoint()
Description copied from interface: Producer
Gets the endpoint this producer sends to.

Specified by:
getEndpoint in interface CometdProducerConsumer
Specified by:
getEndpoint in interface Producer
Overrides:
getEndpoint in class DefaultProducer
Returns:
the endpoint

getBayeux

public org.cometd.server.AbstractBayeux getBayeux()

setBayeux

public void setBayeux(org.cometd.server.AbstractBayeux bayeux)
Description copied from interface: CometdProducerConsumer
Sets the bayeux to use.

Specified by:
setBayeux in interface CometdProducerConsumer


Apache CAMEL