We are using Restful web services in our project. I am passing object of below class to my webservice as Query parameter.
public class QueryDTO {
private String name;
private Object[] args;
private Object[] results;
//with setters and getters
}
Here is my webservice configuration
@GET
@Produces("application/json")
@Path("/")
QueryDTO executeQuery(@QueryParam("") QueryDTO queryDTO) throws Exception;
Here args may contain any of datatypes(String,Interger,Date ..etc ) When I call
rest/query?name="getCreativeExtractorPatternByName"&args={"473"}
I am getting below exception.
Parameter Class java.lang.Object has no constructor with single String parameter, static valueOf(String) or fromString(String) methods
Please help me in resolving this..