Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

parseRecord(bean) does not work #522

Open
pasolid opened this issue May 8, 2023 · 0 comments
Open

parseRecord(bean) does not work #522

pasolid opened this issue May 8, 2023 · 0 comments

Comments

@pasolid
Copy link

pasolid commented May 8, 2023

Your own example/test literally does nothing for writer.processRecord(bean) , prints empty values for the object.

Located in the src/test/java/com/univocity/parsers/examples/WriterExamples.java under test example005WriteFixedWidthUsingAnnotatedBean

For the TestBean object :

        TestBean bean = new TestBean();
        bean.setAmount(new BigDecimal("500.33"));
        bean.setComments("Blah,blah");
        bean.setPending(false);
        bean.setQuantity(100);

It supposed to print:

amount    pending   date    quantity     comments                                
500.33.    false       ?             100         "Bla, blah"                                                                                                            

But instead it prints:

amount    pending   date    quantity     comments                                
?             ?         ?            ?         ?

This explains why I couldn’t make it work...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant