Hi Sergey, everybody
I managed to do some work on Resty-GWT
https://github.com/resty-gwt/resty-gwt/issues/195
https://github.com/resty-gwt/resty-gwt/pull/196
With the patches (not yet applied) I can transmit and receive plain
List<Entity> with no wrapper object.
Now I am hitting another roadblock and any input, especially from you
Sergey is highly appreciated. I am trying to transmit a list of lists
List<List<Entity>>. With my patches applied RestyGWT sends something
like this in @FormParam
public void test(@FormParam("lists-of-entities") List<List<Entity>>);
the play load is
lists-of-entities:[...json representation of List<Entity> as json array ]
lists-of-entities:[...json representation of List<Entity> as json array ]
Now I am expecting my ParamConverter to be called with List<Entity> type
but it is called with plain Entity and it fails because it tries to
deserialize an array. Now why it is doing that? From my interpretation
of the standard is that it should break the outer list to multiple
parameters with the same name. How it can expect to do the same with the
inner list? There is not enough information to assemble it back.
I tried to register also a MessageBodyReader but that also failed. Its
functions are not called at all, while at the same time
MessageBodyWriter is getting called and it works all right. Note that I
have one class implementing ParamConverterProvider, MessageBodyWriter,
MessageBodyReader. Any ideas why it is not working?
Vassilis
--
__________________________________
Vassilis Virvilis Ph.D.
Head of IT
Biovista Inc.
US Offices
2421 Ivy Road
Charlottesville, VA 22903
USA
T: +1.434.971.1141
F: +1.434.971.1144
European Offices
34 Rodopoleos Street
Ellinikon, Athens 16777
GREECE
T: +30.210.9629848
F: +30.210.9647606
www.biovista.com
Biovista is a privately held biotechnology company that finds novel uses
for existing drugs, and profiles their side effects using their
mechanism of action. Biovista develops its own pipeline of drugs in CNS,
oncology, auto-immune and rare diseases. Biovista is collaborating with
biopharmaceutical companies on indication expansion and de-risking of
their portfolios and with the FDA on adverse event prediction.