I want to load a list of POJO from my yaml file. Is it possible for me to do that using snake yaml?
my yaml file looks something like this --
- pty1:val1
pty2:val2
- pty1:val1
pty2:val2
And my pojo -
class pojo {
String pty1;
String pty2;
}
Snakeyaml documentation does say to use loadAs() but that loads a single element. Can I load list of such elements with automatic type binding?
Thanks!
I've started using Jackson's YAML format plugin for serializing and deserializing YAML. Quite friendly.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With