Skip to content

Commit

Permalink
fix json classname fillin to use spec defined var
Browse files Browse the repository at this point in the history
  • Loading branch information
ajm01 committed Oct 26, 2023
1 parent 6673de4 commit 398710c
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions jakarta.ls/src/main/resources/persistence.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
"@Entity",
"@Table(name = \"${2:entityName}\")",
"@NamedQuery(name=\"\", query=\"\")",
"public class ${2:classname} {",
"public class ${TM_FILENAME_BASE} {",
"",
"\t@GeneratedValue(strategy = GenerationType.AUTO)",
"\t@Id",
Expand All @@ -61,7 +61,7 @@
"\t@Column(name=\"${4:columnName}\")",
"\tprivate String ${4:columnName};",
"",
"\tpublic ${2:classname}() { ",
"\tpublic ${TM_FILENAME_BASE}() { ",
"\t}",
"",
"\tpublic int getId() {",
Expand Down
2 changes: 1 addition & 1 deletion jakarta.ls/src/main/resources/restfulWs.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"import jakarta.ws.rs.core.MediaType;",
"",
"@Path(\"${2:/path}\")",
"public class ${3:classname} {",
"public class ${TM_FILENAME_BASE} {",
"",
"\t@GET",
"\t@Produces(MediaType.TEXT_PLAIN)",
Expand Down
8 changes: 4 additions & 4 deletions jakarta.ls/src/main/resources/servlet.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"import jakarta.servlet.ServletException;",
"import java.io.IOException;",
"",
"public class ${2:classname} extends GenericServlet {",
"public class ${TM_FILENAME_BASE} extends GenericServlet {",
"\t@Override",
"\tpublic void service(ServletRequest req, ServletResponse res) throws ServletException, IOException {",
"\t\tres.setContentType(\"text/html\");",
Expand All @@ -37,7 +37,7 @@
"import java.io.IOException;",
"",
"@WebServlet(name = \"${2:servletName}\", urlPatterns = { \"/${3:path}\" })",
"public class ${4:classname} extends HttpServlet {",
"public class ${TM_FILENAME_BASE} extends HttpServlet {",
"\t@Override",
"\tprotected void doGet(HttpServletRequest req, HttpServletResponse res) throws ServletException, IOException {",
"\t\tres.setContentType(\"text/html;charset=UTF-8\");",
Expand All @@ -64,7 +64,7 @@
"import java.io.IOException;",
"",
"@WebServlet(name = \"${2:servletName}\", urlPatterns = { \"/${3:path}\" })",
"public class ${4:classname} extends HttpServlet {",
"public class ${TM_FILENAME_BASE} extends HttpServlet {",
"\t@Override",
"\tprotected void doPost(HttpServletRequest req, HttpServletResponse res) throws ServletException, IOException {",
"\t\tres.setContentType(\"text/html;charset=UTF-8\");",
Expand Down Expand Up @@ -95,7 +95,7 @@
"import java.io.IOException;",
"",
"@WebFilter(filterName = \"${2:filterName}\", urlPatterns = {\"${3:urlPattern}\"})",
"public class ${4:classname} implements Filter {",
"public class ${TM_FILENAME_BASE} implements Filter {",
"\t@Override",
"\tpublic void doFilter(ServletRequest req, ServletResponse res, FilterChain chain) throws IOException, ServletException{",
"\t\tchain.doFilter(req, res);",
Expand Down

0 comments on commit 398710c

Please sign in to comment.