IDEA ---How to configure IDEA to effectively simplify servlet?

The problem was discovered : every time a servlet file is created, @WebServlet always needs to be modified, and at the same time typed in the doGet method,this.doPost(request,response);which is very troublesome and affects the mood.


Requirements : Find a way to automatically set the format we want every time a servlet file is created


Implementation :
File — Settings… — Enter "code templates" in the search box — Other — Web — Java code templates — Servlet Annotated Class.java — Modify the default code on the right — Apply
Insert picture description here


                               感谢收阅

Guess you like

Origin blog.csdn.net/Forest_2Cat/article/details/107856858