程序包 org.springframework.messaging.support
Provides implementations of
Message
along with a MessageBuilder and MessageHeaderAccessor for building and working with messages and message headers, as well as various MessageChannel
implementations and channel interceptor support.接口概要 接口 说明 ChannelInterceptor Interface for interceptors that are able to view and/or modify theMessages
being sent-to and/or received-from aMessageChannel
.ExecutorChannelInterceptor An extension ofChannelInterceptor
with callbacks to intercept the asynchronous sending of aMessage
to a specific subscriber through anExecutor
.HeaderMapper<T> Generic strategy interface for mappingMessageHeaders
to and from other types of objects.InterceptableChannel AMessageChannel
that maintains a listChannelInterceptors
and allows interception of message sending.MessageHandlingRunnable Extension of theRunnable
interface with methods to obtain theMessageHandler
andMessage
to be handled.MessageHeaderInitializer Callback interface for initializing aMessageHeaderAccessor
.类概要 类 说明 AbstractHeaderMapper<T> A baseHeaderMapper
implementation.AbstractMessageChannel Abstract base class forMessageChannel
implementations.AbstractSubscribableChannel Abstract base class forSubscribableChannel
implementations.ChannelInterceptorAdapter 已过时。 as of 5.0.7ChannelInterceptor
has default methods (made possible by a Java 8 baseline) and can be implemented directly without the need for this no-op adapterErrorMessage AGenericMessage
with aThrowable
payload.ExecutorSubscribableChannel ASubscribableChannel
that sends messages to each of its subscribers.GenericMessage<T> An implementation ofMessage
with a generic payload.IdTimestampMessageHeaderInitializer AMessageHeaderInitializer
to customize the strategy for ID and TIMESTAMP message header generation.ImmutableMessageChannelInterceptor A simpler interceptor that callsMessageHeaderAccessor.setImmutable()
on the headers of messages passed through the preSend method.MessageBuilder<T> MessageHeaderAccessor Wrapper aroundMessageHeaders
that provides extra features such as strongly typed accessors for specific headers, the ability to leave headers in aMessage
mutable, and the option to suppress automatic generation ofid
andtimesteamp
headers.NativeMessageHeaderAccessor MessageHeaderAccessor
sub-class that supports storage and access of headers from an external source such as a message broker.