Spring Integration

org.springframework.integration.twitter
Class OutboundUpdatedStatusMessageHandler

java.lang.Object
  extended by org.springframework.integration.context.IntegrationObjectSupport
      extended by org.springframework.integration.endpoint.AbstractEndpoint
          extended by org.springframework.integration.twitter.AbstractOutboundTwitterEndpointSupport
              extended by org.springframework.integration.twitter.OutboundUpdatedStatusMessageHandler
All Implemented Interfaces:
BeanFactoryAware, BeanNameAware, InitializingBean, Lifecycle, Phased, SmartLifecycle, NamedComponent, MessageHandler

public class OutboundUpdatedStatusMessageHandler
extends AbstractOutboundTwitterEndpointSupport

This class is useful for both sending regular status updates as well as 'replies' or 'mentions'

Since:
2.0
Author:
Josh Long

Field Summary
 
Fields inherited from class org.springframework.integration.twitter.AbstractOutboundTwitterEndpointSupport
configuration, statusUpdateSupport, twitter
 
Fields inherited from class org.springframework.integration.context.IntegrationObjectSupport
logger
 
Constructor Summary
OutboundUpdatedStatusMessageHandler()
           
 
Method Summary
 void handleMessage(Message<?> message)
          Handles the message if possible.
 
Methods inherited from class org.springframework.integration.twitter.AbstractOutboundTwitterEndpointSupport
doStart, doStop, onInit, setConfiguration
 
Methods inherited from class org.springframework.integration.endpoint.AbstractEndpoint
getPhase, isAutoStartup, isRunning, setAutoStartup, setPhase, setTaskScheduler, start, stop, stop
 
Methods inherited from class org.springframework.integration.context.IntegrationObjectSupport
afterPropertiesSet, getBeanFactory, getComponentName, getComponentType, getConversionService, getRequiredMetadataPersister, getTaskScheduler, setBeanFactory, setBeanName, setComponentName, setConversionService, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

OutboundUpdatedStatusMessageHandler

public OutboundUpdatedStatusMessageHandler()
Method Detail

handleMessage

public void handleMessage(Message<?> message)
                   throws MessageRejectedException,
                          MessageHandlingException,
                          MessageDeliveryException
Description copied from interface: MessageHandler
Handles the message if possible. If the handler cannot deal with the message this will result in a MessageRejectedException e.g. in case of a Selective Consumer. When a consumer tries to handle a message, but fails to do so, a MessageHandlingException is thrown. In the last case it is recommended to treat the message as tainted and go into an error scenario.

When the handling results in a failure of another message being sent (e.g. a "reply" message), that failure will trigger a MessageDeliveryException.

Parameters:
message - the message to be handled
Throws:
MessageRejectedException - if the handler doesn't accept the message
MessageHandlingException - when something fails during the handling
MessageDeliveryException - when this handler failed to deliver the reply related to the handling of the message

Spring Integration

Copyright © 2010. All Rights Reserved.