类 AbstractMessagingTemplate<D>

    • 方法详细资料

      • convertSendAndReceive

        public <T> T convertSendAndReceive​(Object request,
                                           Class<T> targetClass)
        从接口复制的说明: MessageRequestReplyOperations
        Convert the given request Object to serialized form, possibly using a MessageConverter, send it as a Message to a default destination, receive the reply and convert its body of the specified target class.
        指定者:
        convertSendAndReceive 在接口中 MessageRequestReplyOperations<D>
        参数:
        request - payload for the request message to send
        targetClass - the target type to convert the payload of the reply to
        返回:
        the payload of the reply message, possibly null if the message could not be received, for example due to a timeout
      • convertSendAndReceive

        public <T> T convertSendAndReceive​(D destination,
                                           Object request,
                                           Class<T> targetClass)
        从接口复制的说明: MessageRequestReplyOperations
        Convert the given request Object to serialized form, possibly using a MessageConverter, send it as a Message to the given destination, receive the reply and convert its body of the specified target class.
        指定者:
        convertSendAndReceive 在接口中 MessageRequestReplyOperations<D>
        参数:
        destination - the target destination
        request - payload for the request message to send
        targetClass - the target type to convert the payload of the reply to
        返回:
        the payload of the reply message, possibly null if the message could not be received, for example due to a timeout
      • convertSendAndReceive

        public <T> T convertSendAndReceive​(D destination,
                                           Object request,
                                           Map<String,​Object> headers,
                                           Class<T> targetClass)
        从接口复制的说明: MessageRequestReplyOperations
        Convert the given request Object to serialized form, possibly using a MessageConverter, send it as a Message with the given headers, to the specified destination, receive the reply and convert its body of the specified target class.
        指定者:
        convertSendAndReceive 在接口中 MessageRequestReplyOperations<D>
        参数:
        destination - the target destination
        request - payload for the request message to send
        headers - headers for the request message to send
        targetClass - the target type to convert the payload of the reply to
        返回:
        the payload of the reply message, possibly null if the message could not be received, for example due to a timeout
      • convertSendAndReceive

        public <T> T convertSendAndReceive​(Object request,
                                           Class<T> targetClass,
                                           MessagePostProcessor postProcessor)
        从接口复制的说明: MessageRequestReplyOperations
        Convert the given request Object to serialized form, possibly using a MessageConverter, apply the given post processor and send the resulting Message to a default destination, receive the reply and convert its body of the given target class.
        指定者:
        convertSendAndReceive 在接口中 MessageRequestReplyOperations<D>
        参数:
        request - payload for the request message to send
        targetClass - the target type to convert the payload of the reply to
        postProcessor - post process to apply to the request message
        返回:
        the payload of the reply message, possibly null if the message could not be received, for example due to a timeout
      • convertSendAndReceive

        public <T> T convertSendAndReceive​(D destination,
                                           Object request,
                                           Class<T> targetClass,
                                           MessagePostProcessor postProcessor)
        从接口复制的说明: MessageRequestReplyOperations
        Convert the given request Object to serialized form, possibly using a MessageConverter, apply the given post processor and send the resulting Message to the given destination, receive the reply and convert its body of the given target class.
        指定者:
        convertSendAndReceive 在接口中 MessageRequestReplyOperations<D>
        参数:
        destination - the target destination
        request - payload for the request message to send
        targetClass - the target type to convert the payload of the reply to
        postProcessor - post process to apply to the request message
        返回:
        the payload of the reply message, possibly null if the message could not be received, for example due to a timeout
      • convertSendAndReceive

        public <T> T convertSendAndReceive​(D destination,
                                           Object request,
                                           Map<String,​Object> headers,
                                           Class<T> targetClass,
                                           MessagePostProcessor postProcessor)
        从接口复制的说明: MessageRequestReplyOperations
        Convert the given request 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 specified destination, receive the reply and convert its body of the given target class.
        指定者:
        convertSendAndReceive 在接口中 MessageRequestReplyOperations<D>
        参数:
        destination - the target destination
        request - payload for the request message to send
        targetClass - the target type to convert the payload of the reply to
        postProcessor - post process to apply to the request message
        返回:
        the payload of the reply message, possibly null if the message could not be received, for example due to a timeout