Interface DeadLetterJdbcConverter<E extends EventMessage,D extends JdbcDeadLetter<E>>
- Type Parameters:
E- An implementation ofEventMessagecontained within theJdbcDeadLetterimplementation this converter converts.D- An implementation ofJdbcDeadLetterconverted by this converter.
- All Known Implementing Classes:
DefaultDeadLetterJdbcConverter
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@FunctionalInterface
public interface DeadLetterJdbcConverter<E extends EventMessage,D extends JdbcDeadLetter<E>>
A functional interface describing how to convert a
ResultSet in JdbcDeadLetter implementation of type
D- Since:
- 4.8.0
- Author:
- Steven van Beelen
-
Method Summary
Modifier and TypeMethodDescriptionconvertToLetter(ResultSet resultSet) Converts the givenresultSetin an implementation ofJdbcDeadLetter.
-
Method Details
-
convertToLetter
Converts the givenresultSetin an implementation ofJdbcDeadLetter.It is recommended to validate the type of
EventMessageto place in the result, as different types require additional information to be deserialized and returned.- Parameters:
resultSet- TheResultSetto convert into aJdbcDeadLetter- Returns:
- An implementation of
JdbcDeadLetterbased on the givenresultSet. - Throws:
SQLException- if the acolumnLabelin the givenresultSetdoes not exist, if a database access error occurs or if the givenresultSetis closed.
-