public abstract class AbstractPollableChannel extends AbstractMessageChannel implements org.springframework.messaging.PollableChannel, ExecutorChannelInterceptorAware
AbstractMessageChannel.ChannelInterceptorListIntegrationManagement.ManagementOverridesinterceptors, metersEXPRESSION_PARSER, loggerMETER_PREFIX, RECEIVE_COUNTER_NAME, SEND_TIMER_NAME| Constructor and Description |
|---|
AbstractPollableChannel() |
| Modifier and Type | Method and Description |
|---|---|
void |
addInterceptor(org.springframework.messaging.support.ChannelInterceptor interceptor)
Add a channel interceptor to the end of the list.
|
void |
addInterceptor(int index,
org.springframework.messaging.support.ChannelInterceptor interceptor)
Add a channel interceptor to the specified index of the list.
|
protected abstract org.springframework.messaging.Message<?> |
doReceive(long timeout)
Subclasses must implement this method.
|
IntegrationPatternType |
getIntegrationPatternType()
Return a pattern type this component implements.
|
boolean |
hasExecutorInterceptors() |
org.springframework.messaging.Message<?> |
receive()
Receive the first available message from this channel.
|
org.springframework.messaging.Message<?> |
receive(long timeout)
Receive the first available message from this channel.
|
boolean |
removeInterceptor(org.springframework.messaging.support.ChannelInterceptor interceptor) |
org.springframework.messaging.support.ChannelInterceptor |
removeInterceptor(int index) |
void |
setInterceptors(java.util.List<org.springframework.messaging.support.ChannelInterceptor> interceptors)
Set the list of channel interceptors.
|
destroy, doSend, getComponentType, getFullChannelName, getIChannelInterceptorList, getInterceptors, getMetricsCaptor, getOverrides, isLoggingEnabled, onInit, registerMetricsCaptor, send, send, setDatatypes, setLoggingEnabled, setMessageConverter, setShouldTrackafterPropertiesSet, extractTypeIfPossible, generateId, getApplicationContext, getApplicationContextId, getBeanDescription, getBeanFactory, getBeanName, getChannelResolver, getComponentName, getConversionService, getExpression, getIntegrationProperties, getIntegrationProperty, getMessageBuilderFactory, getTaskScheduler, isInitialized, setApplicationContext, setBeanFactory, setBeanName, setChannelResolver, setComponentName, setConversionService, setMessageBuilderFactory, setPrimaryExpression, setTaskScheduler, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetInterceptorsgetManagedName, getManagedType, getThisAs, setManagedName, setManagedTypegetBeanName, getComponentNamepublic IntegrationPatternType getIntegrationPatternType()
IntegrationPatterngetIntegrationPatternType in interface IntegrationPatterngetIntegrationPatternType in class AbstractMessageChannelIntegrationPatternType this component implements.@Nullable public org.springframework.messaging.Message<?> receive()
receive in interface org.springframework.messaging.PollableChannelnull if the
receiving thread is interrupted.@Nullable public org.springframework.messaging.Message<?> receive(long timeout)
receive()).receive in interface org.springframework.messaging.PollableChanneltimeout - the timeout in millisecondsnull if no message
is available within the allotted time or the receiving thread is
interrupted.public void setInterceptors(java.util.List<org.springframework.messaging.support.ChannelInterceptor> interceptors)
AbstractMessageChannelsetInterceptors in interface org.springframework.messaging.support.InterceptableChannelsetInterceptors in class AbstractMessageChannelinterceptors - The list of interceptors.public void addInterceptor(org.springframework.messaging.support.ChannelInterceptor interceptor)
AbstractMessageChanneladdInterceptor in interface org.springframework.messaging.support.InterceptableChanneladdInterceptor in class AbstractMessageChannelinterceptor - The interceptor.public void addInterceptor(int index,
org.springframework.messaging.support.ChannelInterceptor interceptor)
AbstractMessageChanneladdInterceptor in interface org.springframework.messaging.support.InterceptableChanneladdInterceptor in class AbstractMessageChannelindex - The index to add interceptor.interceptor - The interceptor.public boolean removeInterceptor(org.springframework.messaging.support.ChannelInterceptor interceptor)
removeInterceptor in interface org.springframework.messaging.support.InterceptableChannelremoveInterceptor in class AbstractMessageChannel@Nullable public org.springframework.messaging.support.ChannelInterceptor removeInterceptor(int index)
removeInterceptor in interface org.springframework.messaging.support.InterceptableChannelremoveInterceptor in class AbstractMessageChannelpublic boolean hasExecutorInterceptors()
hasExecutorInterceptors in interface ExecutorChannelInterceptorAware@Nullable protected abstract org.springframework.messaging.Message<?> doReceive(long timeout)
timeout - The timeout.