samedi 13 août 2016

How to read the comment of method and add annotation accordingly?

Suppose I have the following method:

/** Account Types */
@ResponseBody
@Secured("ROLE_AccountTypes")
@RequestMapping(value = "/accountTypes", method = RequestMethod.GET, produces = MediaType.APPLICATION_JSON_VALUE)
public List<T> getAccountTypes() {

  return accountSrv.getAccountTypes();
}

Now I want to put the comment of the method in a custom annotation programmatically. How is that possible?





Aucun commentaire:

Enregistrer un commentaire