java - Read array of unknown objects in REST service -


how write rest service below data post request? templates can have data, array of data.

{    "name":"jose",    "surname":"john",    "templates":[       {          "template1":"333",          "any":"any"       },       {          "anything":"anything",          "test":"tafsasdf"       }    ] } 

cxf knows how convert such string nested map<string, object>. need have jackson libraries in classpath , annotate server method @requestbody.

something this:

@requestbody public void somemethod(map<string, object> json objects) {      // code here } 

Comments

Popular posts from this blog

javascript - Count length of each class -

What design pattern is this code in Javascript? -

hadoop - Restrict secondarynamenode to be installed and run on any other node in the cluster -