hpehl / piriti

JSON and XML Mapper for GWT
40 stars 16 forks source link

using mappings on XmlReaderWriter doesn't generate with correct paths #23

Closed gryffindor14 closed 9 years ago

gryffindor14 commented 9 years ago

@Mappings({ @Mapping(value="fName", path="FirstName"), @Mapping(value="lName", path="LastName") }) interface ReaderWriter extends XmlReaderWriter{}

with public class Name{ String fName; String lName" } generates a reader and writer looking for the paths lName and fName in the xml. It works correctly if you create and separate reader and writer using the mappings with following Xml:

`

john doe

`

gryffindor14 commented 9 years ago

I'm going to close this issue since it seems like this is just a generated helper class and doesn't do any generation itself. You need to create a reader and writer interface with mappings for every POJO you want to correspondingly read and write and bind this helper class as a singleton or static member of a class