Karteek Chenna
unread,Jun 29, 2012, 2:51:20 PM6/29/12Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to json...@googlegroups.com
I have a requirement where I need to create a service where my parameters are java POJO/DTO objects.
How to I represent my POJO as in JSONRPC format and use with jsonrpc4j.?
Example:
public User implements Serializable{
private static final long serialVersionUID = 1L;
private String userName;
private Strin pswd;
/* And Getter Setter Methods & toString() Methods in my DTO*/
}
Service Interface
---------------------
public UserService {
public String processUserRecord(@JsonRpcParam("userRecord") User userRecord);
}
How do I represent this Object in JSON RPC format and also use JSPN RPC to invoke my JSON Service
Is this correct format of JSON_RPC for above User Object
{"jsonrpc": "2.0", "method": "processUserRecord", "params":{"userRecord":{"userName":"testUser","pswd","testPswd"}}, "id": 1}