How it works...

Creating a multi-action controller is quite easy and simple because each handler method has its own @RequestMapping setup. Each method can be mapped to any HTTP method without having conflict with the others. The only problem is the high possibility of creating ambiguous URL mappings once the list of handlers increases in number. To solve this case, it is mandatory to create a default method such as defaultMethod() to filter an ambiguous and erroneous URL of the @Controller. The asterisk (*) means all the possible patterns of the path excluding those URLs declared. Just be cautious with the use of @RequestMapping("/*") since it will filter all possible URLs of the WebApplicationContext.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.217.254.118