0
我的代碼如下所示。在寧靜的web服務應用程序中獲取com.sun.jersey.api.MessageException
@Produces(MediaType.TEXT_XML)
public Response getEmpDetails() {
Map<String, Employee> result = empDaoo.getEmpInfo();
return Response.status(200).entity(result).build();
}
然後我得到這個異常:
SEVERE: Mapped exception to response: 500 (Internal Server Error)
javax.ws.rs.WebApplicationException: com.sun.jersey.api.MessageException: A message body writer for Java class java.util.HashMap, and Java type class java.util.HashMap, and MIME media type text/xml was not found
任何一個可以提供解決方案PLZ。 快速反應PLZ ...
我沒有得到任何東西你可以plz詳細說明......... – rahul
你有JAXB的經驗嗎? –