@Test void testWriteMessageNotSupported() throws Exception { assertThatThrownBy( () -> new NotificationRequestConverter(new StringMessageConverter()) .toMessage("test", null)) .isInstanceOf(UnsupportedOperationException.class); }
@Override public Message<?> toMessage(Object payload, MessageHeaders headers) { throw new UnsupportedOperationException( "This converter only supports reading a SNS notification and not writing them"); }
NotificationRequestConverter implements MessageConverter { @Override public Message<?> toMessage(Object payload, MessageHeaders headers) { throw new UnsupportedOperationException( "This converter only supports reading a SNS notification and not writing them"); } }
NotificationRequestConverter implements MessageConverter { @Override public Message<?> toMessage(Object payload, MessageHeaders headers) { throw new UnsupportedOperationException( "This converter only supports reading a SNS notification and not writing them"); } NotificationRequestConverter(MessageConverter payloadConverter); }
NotificationRequestConverter implements MessageConverter { @Override public Message<?> toMessage(Object payload, MessageHeaders headers) { throw new UnsupportedOperationException( "This converter only supports reading a SNS notification and not writing them"); } NotificationRequestConverter(MessageConverter payloadConverter); @Override Object fromMessage(Message<?> message, Class<?> targetClass); @Override Message<?> toMessage(Object payload, MessageHeaders headers); }
NotificationRequestConverter implements MessageConverter { @Override public Message<?> toMessage(Object payload, MessageHeaders headers) { throw new UnsupportedOperationException( "This converter only supports reading a SNS notification and not writing them"); } NotificationRequestConverter(MessageConverter payloadConverter); @Override Object fromMessage(Message<?> message, Class<?> targetClass); @Override Message<?> toMessage(Object payload, MessageHeaders headers);  }