/** * Create a {@link JmsResponse} targeting the specified {@link Destination}. */ public static <T> JmsResponse<T> forDestination(T result, Destination destination) { Assert.notNull(destination, "Destination must not be null"); return new JmsResponse<>(result, destination); }
/** * Create a {@link JmsResponse} targeting the queue with the specified name. */ public static <T> JmsResponse<T> forQueue(T result, String queueName) { Assert.notNull(queueName, "Queue name must not be null"); return new JmsResponse<>(result, new DestinationNameHolder(queueName, false)); }
/** * Create a {@link JmsResponse} targeting the topic with the specified name. */ public static <T> JmsResponse<T> forTopic(T result, String topicName) { Assert.notNull(topicName, "Topic name must not be null"); return new JmsResponse<>(result, new DestinationNameHolder(topicName, true)); }
public JmsResponse<String> replyPayloadNoDestination(Message<String> input) { return new JmsResponse<>(input.getPayload(), null); }
/** * Create a {@link JmsResponse} targeting the specified {@link Destination}. */ public static <T> JmsResponse<T> forDestination(T result, Destination destination) { Assert.notNull(destination, "Destination must not be null"); return new JmsResponse<T>(result, destination); }
/** * Create a {@link JmsResponse} targeting the specified {@link Destination}. */ public static <T> JmsResponse<T> forDestination(T result, Destination destination) { Assert.notNull(destination, "Destination must not be null"); return new JmsResponse<>(result, destination); }
/** * Create a {@link JmsResponse} targeting the topic with the specified name. */ public static <T> JmsResponse<T> forTopic(T result, String topicName) { Assert.notNull(topicName, "Topic name must not be null"); return new JmsResponse<T>(result, new DestinationNameHolder(topicName, true)); }
/** * Create a {@link JmsResponse} targeting the queue with the specified name. */ public static <T> JmsResponse<T> forQueue(T result, String queueName) { Assert.notNull(queueName, "Queue name must not be null"); return new JmsResponse<>(result, new DestinationNameHolder(queueName, false)); }
/** * Create a {@link JmsResponse} targeting the topic with the specified name. */ public static <T> JmsResponse<T> forTopic(T result, String topicName) { Assert.notNull(topicName, "Topic name must not be null"); return new JmsResponse<>(result, new DestinationNameHolder(topicName, true)); }
/** * Create a {@link JmsResponse} targeting the queue with the specified name. */ public static <T> JmsResponse<T> forQueue(T result, String queueName) { Assert.notNull(queueName, "Queue name must not be null"); return new JmsResponse<T>(result, new DestinationNameHolder(queueName, false)); }