How to find type of Annotated function parameter

Suppose I have a function public int doSomething(@QueryParam("id") String name, int x){ .... } How can I find the type of the annotated parameter 'name'. I have a handle to the `java.lang.reflect.Method` instance of the function doSomething and using the function `getParameterAnnotations()`, I can obtain the annotation `@QueryParam` but am not able to access the parameter on which it is applied on. How do I do this ?

以上就是How to find type of Annotated function parameter的详细内容,更多请关注web前端其它相关文章!

赞(0) 打赏
未经允许不得转载:web前端首页 » JavaScript 答疑

评论 抢沙发

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址

前端开发相关广告投放 更专业 更精准