Hi folks,
for those of you using the REST API provided by Restful Objects viewer, you
might be interested to know that we now have enhanced support for content
negotation ("conneg").
For example, if you call an object representation with an Accept header of:
"application/xml;profile=urn:org.restfulobjects:repr-types/object;x-ro-domain-type=com.mycompany.myapp.CustomerDto"
then the framework will look for an implementation of a
ContentMappingService and try to map the actual result (eg a Customer) to
the required result (eg a CustomerDto).
This works for both application/xml (marshalled using JAXB) and
application/json (marshalled using Jackson).
I'll be adding some proper docs on this, but for now you can take a look at
the README for the todoapp on isis addons [1]
Cheers
Dan
[1] https://github.com/isisaddons/isis-app-todoapp#rest-api