final PreparedStatement ps = connection.prepareStatement("SELECT 2 as l, 'c' as c");
final ResultSet rs = ps.executeQuery();
final TypeMapper<?> mapper = TypeMapperFactory.createTypeMapper(ClassWithColumnDefinition.class);
int i = 0;
while (rs.next()) {
final ClassWithColumnDefinition result = (ClassWithColumnDefinition) mapper.mapRow(rs, i++);
Assert.assertNotNull(result);
Assert.assertEquals(2, result.getL());
Assert.assertEquals('c', result.getC());
}
}