File location information for Objects

7 views
Skip to first unread message

Amir Bar-or

unread,
Jan 2, 2014, 10:36:19 AM1/2/14
to jacks...@googlegroups.com
Hi,

We are using Jackson and YAML and we have a validation pass after the objects have been created (no parsing error).  I would like to report issues with the location info (first line/character) for the objects. Is it possible to somehow retrieve it?  Can this be a new annotation we can add to our objects that wish to retain location info?

Tatu Saloranta

unread,
Jan 2, 2014, 10:38:02 PM1/2/14
to jacks...@googlegroups.com
If underlying YAML parser (SnakeYAML) can provide location information, it should be possible to connect it, same way as JSON parser does it. No annotation s are needed. But location information is only available during parsing; data binding functionality has no place to store it, so validation would either need to be done incrementally (like wrapping the resulting parser), or by building a custom model that keeps track of location information.

-+ Tatu +-


On Thu, Jan 2, 2014 at 3:36 PM, Amir Bar-or <aba...@gmail.com> wrote:
Hi,

We are using Jackson and YAML and we have a validation pass after the objects have been created (no parsing error).  I would like to report issues with the location info (first line/character) for the objects. Is it possible to somehow retrieve it?  Can this be a new annotation we can add to our objects that wish to retain location info?

--
You received this message because you are subscribed to the Google Groups "jackson-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jackson-dev...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply all
Reply to author
Forward
0 new messages