Fix javaJaxRS template: remove deprecated in JDK9 method usage (#18728)

* Fix javaJaxRS template: remove deprecated in JDK9 method usage

* Fix javaJaxRS api template: regenerate samples
This commit is contained in:
Ievgen Rozdymakha
2024-05-26 10:58:41 +03:00
committed by GitHub
parent 728abafdfa
commit 0daf9ffa5b
26 changed files with 26 additions and 26 deletions

View File

@@ -47,7 +47,7 @@ public class {{classname}} {
String implClass = servletContext.getInitParameter("{{classname}}.implementation");
if (implClass != null && !"".equals(implClass.trim())) {
try {
delegate = ({{classname}}Service) Class.forName(implClass).newInstance();
delegate = ({{classname}}Service) Class.forName(implClass).getDeclaredConstructor().newInstance();
} catch (Exception e) {
throw new RuntimeException(e);
}