Subresource for target class has no jax-rs annotations

来源:互联网 发布:菠萝饭官方软件 编辑:程序博客网 时间:2024/05/01 00:14

Subresource for target class has no jax-rs annotations

Error: Subresource for target class has no jax-rs annotations.: classname that prevented it from fulfilling this request.
Context:  @Path(“foo”) JAXRSAccount JAXRSAccounts.getAccount()
Resolution: Check that the sub-resource (JAXRSAccount) has at least one method with a @GET/POST/etc annotation.  

And check it is declared as public.

这个错误表示没有找到@Method注释的方法,需要在对应的方法增加@GET或者@POST 等方法的注解。

来自:http://blog.2partsmagic.com/2009/04/subresource-for-target-class-has-no-jax-rs-annotations/

0 0