public class CamelMessageConsumer extends Object implements MessageConsumer
MessageConsumer
which consumes message exchanges from
a Camel Endpoint
Constructor and Description |
---|
CamelMessageConsumer(CamelDestination destination,
org.apache.camel.Endpoint endpoint,
ActiveMQSession session,
String messageSelector,
boolean noLocal) |
Modifier and Type | Method and Description |
---|---|
protected void |
checkClosed() |
void |
close() |
protected org.apache.camel.Consumer |
createConsumer() |
protected Message |
createMessage(org.apache.camel.Exchange exchange) |
CamelDestination |
getDestination() |
org.apache.camel.Endpoint |
getEndpoint() |
MessageListener |
getMessageListener() |
String |
getMessageSelector() |
protected org.apache.camel.PollingConsumer |
getPollingConsumer() |
ActiveMQSession |
getSession() |
boolean |
isNoLocal() |
Message |
receive() |
Message |
receive(long timeoutMillis) |
Message |
receiveNoWait() |
void |
setMessageListener(MessageListener messageListener) |
public CamelMessageConsumer(CamelDestination destination, org.apache.camel.Endpoint endpoint, ActiveMQSession session, String messageSelector, boolean noLocal)
public void close() throws JMSException
close
in interface MessageConsumer
JMSException
public MessageListener getMessageListener() throws JMSException
getMessageListener
in interface MessageConsumer
JMSException
public void setMessageListener(MessageListener messageListener) throws JMSException
setMessageListener
in interface MessageConsumer
JMSException
public Message receive() throws JMSException
receive
in interface MessageConsumer
JMSException
public Message receive(long timeoutMillis) throws JMSException
receive
in interface MessageConsumer
JMSException
public Message receiveNoWait() throws JMSException
receiveNoWait
in interface MessageConsumer
JMSException
public CamelDestination getDestination()
public org.apache.camel.Endpoint getEndpoint()
public String getMessageSelector()
getMessageSelector
in interface MessageConsumer
public boolean isNoLocal()
public ActiveMQSession getSession()
protected org.apache.camel.PollingConsumer getPollingConsumer() throws JMSException
JMSException
protected Message createMessage(org.apache.camel.Exchange exchange) throws JMSException
JMSException
protected org.apache.camel.Consumer createConsumer() throws JMSException
JMSException
protected void checkClosed() throws IllegalStateException
IllegalStateException
Copyright © 2005–2016 FuseSource, Corp.. All rights reserved.