Class ChatMessageListeningEndpoint

java.lang.Object
org.springframework.integration.context.IntegrationObjectSupport
org.springframework.integration.endpoint.AbstractEndpoint
org.springframework.integration.endpoint.MessageProducerSupport
org.springframework.integration.xmpp.core.AbstractXmppConnectionAwareEndpoint
org.springframework.integration.xmpp.inbound.ChatMessageListeningEndpoint
All Implemented Interfaces:
org.springframework.beans.factory.Aware, org.springframework.beans.factory.BeanFactoryAware, org.springframework.beans.factory.BeanNameAware, org.springframework.beans.factory.DisposableBean, org.springframework.beans.factory.InitializingBean, org.springframework.beans.factory.SmartInitializingSingleton, org.springframework.context.ApplicationContextAware, org.springframework.context.Lifecycle, org.springframework.context.Phased, org.springframework.context.SmartLifecycle, org.springframework.integration.context.ExpressionCapable, org.springframework.integration.core.MessageProducer, org.springframework.integration.IntegrationPattern, org.springframework.integration.support.context.NamedComponent, org.springframework.integration.support.management.ManageableLifecycle, org.springframework.integration.support.management.ManageableSmartLifecycle, org.springframework.integration.support.management.TrackableComponent

public class ChatMessageListeningEndpoint
extends AbstractXmppConnectionAwareEndpoint
This component logs in as a user and forwards any messages to that user on to downstream components.
Since:
2.0
  • Field Summary

    Fields inherited from class org.springframework.integration.endpoint.AbstractEndpoint

    lifecycleCondition, lifecycleLock

    Fields inherited from class org.springframework.integration.context.IntegrationObjectSupport

    EXPRESSION_PARSER, logger

    Fields inherited from interface org.springframework.context.SmartLifecycle

    DEFAULT_PHASE
  • Constructor Summary

    Constructors 
    Constructor Description
    ChatMessageListeningEndpoint()  
    ChatMessageListeningEndpoint​(org.jivesoftware.smack.XMPPConnection xmppConnection)  
  • Method Summary

    Modifier and Type Method Description
    protected void doStart()  
    protected void doStop()  
    java.lang.String getComponentType()  
    protected void onInit()  
    void setHeaderMapper​(XmppHeaderMapper headerMapper)  
    void setPayloadExpression​(org.springframework.expression.Expression payloadExpression)
    Specify a SpEL expression to evaluate a payload against an incoming Message.
    void setStanzaFilter​(org.jivesoftware.smack.filter.StanzaFilter stanzaFilter)
    Specify a StanzaFilter to use for the incoming packets.

    Methods inherited from class org.springframework.integration.xmpp.core.AbstractXmppConnectionAwareEndpoint

    getXmppConnection, isInitialized

    Methods inherited from class org.springframework.integration.endpoint.MessageProducerSupport

    afterSingletonsInstantiated, buildErrorMessage, getErrorChannel, getErrorMessageAttributes, getIntegrationPatternType, getMessagingTemplate, getOutputChannel, sendErrorMessageIfNecessary, sendMessage, setErrorChannel, setErrorChannelName, setErrorMessageStrategy, setOutputChannel, setOutputChannelName, setSendTimeout, setShouldTrack, subscribeToPublisher

    Methods inherited from class org.springframework.integration.endpoint.AbstractEndpoint

    destroy, doStop, getPhase, getRole, isActive, isAutoStartup, isRunning, setAutoStartup, setPhase, setRole, start, stop, stop

    Methods inherited from class org.springframework.integration.context.IntegrationObjectSupport

    afterPropertiesSet, extractTypeIfPossible, generateId, getApplicationContext, getApplicationContextId, getBeanDescription, getBeanFactory, getBeanName, getChannelResolver, getComponentName, getConversionService, getExpression, getIntegrationProperties, getIntegrationProperty, getMessageBuilderFactory, getTaskScheduler, setApplicationContext, setBeanFactory, setBeanName, setChannelResolver, setComponentName, setConversionService, setMessageBuilderFactory, setPrimaryExpression, setTaskScheduler, toString

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

    Methods inherited from interface org.springframework.integration.support.context.NamedComponent

    getBeanName, getComponentName
  • Constructor Details

  • Method Details

    • setHeaderMapper

      public void setHeaderMapper​(XmppHeaderMapper headerMapper)
    • setStanzaFilter

      public void setStanzaFilter​(org.jivesoftware.smack.filter.StanzaFilter stanzaFilter)
      Specify a StanzaFilter to use for the incoming packets.
      Parameters:
      stanzaFilter - the StanzaFilter to use
      Since:
      4.3
      See Also:
      XMPPConnection.addAsyncStanzaListener(StanzaListener, StanzaFilter)
    • setPayloadExpression

      public void setPayloadExpression​(org.springframework.expression.Expression payloadExpression)
      Specify a SpEL expression to evaluate a payload against an incoming Message.
      Parameters:
      payloadExpression - the Expression for payload evaluation.
      Since:
      4.3
      See Also:
      StanzaListener, Message
    • getComponentType

      public java.lang.String getComponentType()
      Specified by:
      getComponentType in interface org.springframework.integration.support.context.NamedComponent
      Overrides:
      getComponentType in class org.springframework.integration.context.IntegrationObjectSupport
    • onInit

      protected void onInit()
      Overrides:
      onInit in class AbstractXmppConnectionAwareEndpoint
    • doStart

      protected void doStart()
      Overrides:
      doStart in class org.springframework.integration.endpoint.MessageProducerSupport
    • doStop

      protected void doStop()
      Overrides:
      doStop in class org.springframework.integration.endpoint.MessageProducerSupport