接口 DestinationResolvingMessageSendingOperations<D>

    • 方法详细资料

      • send

        void send​(String destinationName,
                  Message<?> message)
           throws MessagingException
        Resolve the given destination name to a destination and send a message to it.
        参数:
        destinationName - the destination name to resolve
        message - the message to send
        抛出:
        MessagingException
      • convertAndSend

        <T> void convertAndSend​(String destinationName,
                                T payload)
                         throws MessagingException
        Resolve the given destination name to a destination, convert the payload Object to serialized form, possibly using a MessageConverter, wrap it as a message and send it to the resolved destination.
        参数:
        destinationName - the destination name to resolve
        payload - the Object to use as payload
        抛出:
        MessagingException
      • convertAndSend

        <T> void convertAndSend​(String destinationName,
                                T payload,
                                Map<String,​Object> headers)
                         throws MessagingException
        Resolve the given destination name to a destination, convert the payload Object to serialized form, possibly using a MessageConverter, wrap it as a message with the given headers and send it to the resolved destination.
        参数:
        destinationName - the destination name to resolve
        payload - the Object to use as payload
        headers - headers for the message to send
        抛出:
        MessagingException
      • convertAndSend

        <T> void convertAndSend​(String destinationName,
                                T payload,
                                MessagePostProcessor postProcessor)
                         throws MessagingException
        Resolve the given destination name to a destination, convert the payload Object to serialized form, possibly using a MessageConverter, wrap it as a message, apply the given post processor, and send the resulting message to the resolved destination.
        参数:
        destinationName - the destination name to resolve
        payload - the Object to use as payload
        postProcessor - the post processor to apply to the message
        抛出:
        MessagingException
      • convertAndSend

        <T> void convertAndSend​(String destinationName,
                                T payload,
                                Map<String,​Object> headers,
                                MessagePostProcessor postProcessor)
                         throws MessagingException
        Resolve the given destination name to a destination, convert the payload Object to serialized form, possibly using a MessageConverter, wrap it as a message with the given headers, apply the given post processor, and send the resulting message to the resolved destination.
        参数:
        destinationName - the destination name to resolve
        payload - the Object to use as payload
        headers - headers for the message to send
        postProcessor - the post processor to apply to the message
        抛出:
        MessagingException