@RequestMapping(value = “/hospitals/{id}”, method = RequestMethod.GET) How to get the value of id in controller method?”

Questions & AnswersCategory: Programming Language@RequestMapping(value = “/hospitals/{id}”, method = RequestMethod.GET) How to get the value of id in controller method?”
Pavan Kumar asked 2 years ago

@RequestMapping(value = “/hospitals/{id}”, method = RequestMethod.GET) How to get the value of id in controller method?”
a. @Variable(“d”)
b. @PathVariable(“id”)
c. None of the options
d. @RequestVariable(“id”)
e. @RequestMapping(“id�)