hpehl / piriti

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

Added support for lists to serialize child element with tags based on their class name #11

Closed lathil closed 11 years ago

lathil commented 11 years ago

Added a way for objects being in a List to be serialised with a tag name that use the object class name.

For example, here below is a Car object that contains a List property named childrens. In this list are a Motor and Wheel objects. By setting path='', the serialised doc will be:

@Mappings({

@Mapping( value="childrens", path="" ),

})

public interface CarXmlWriter extends XmlWriter {

}