Add more missing type arguments for generic class Class<T>
Change-Id: I3ff55e9443074133fa19cbe4818c82d8be27e467
This commit is contained in:
@@ -39,7 +39,7 @@ class PluginServletContext {
|
|||||||
return (ServletContext)
|
return (ServletContext)
|
||||||
Proxy.newProxyInstance(
|
Proxy.newProxyInstance(
|
||||||
PluginServletContext.class.getClassLoader(),
|
PluginServletContext.class.getClassLoader(),
|
||||||
new Class[] {ServletContext.class, API.class},
|
new Class<?>[] {ServletContext.class, API.class},
|
||||||
new Handler(plugin, contextPath));
|
new Handler(plugin, contextPath));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -200,7 +200,8 @@ public final class GerritLauncher {
|
|||||||
if ((main.getModifiers() & Modifier.STATIC) == Modifier.STATIC) {
|
if ((main.getModifiers() & Modifier.STATIC) == Modifier.STATIC) {
|
||||||
res = main.invoke(null, new Object[] {argv});
|
res = main.invoke(null, new Object[] {argv});
|
||||||
} else {
|
} else {
|
||||||
res = main.invoke(clazz.getConstructor(new Class[] {}).newInstance(), new Object[] {argv});
|
res =
|
||||||
|
main.invoke(clazz.getConstructor(new Class<?>[] {}).newInstance(), new Object[] {argv});
|
||||||
}
|
}
|
||||||
} catch (InvocationTargetException ite) {
|
} catch (InvocationTargetException ite) {
|
||||||
if (ite.getCause() instanceof Exception) {
|
if (ite.getCause() instanceof Exception) {
|
||||||
|
|||||||
@@ -52,10 +52,10 @@ class OperatingSystemMXBeanProvider {
|
|||||||
private OperatingSystemMXBeanProvider(OperatingSystemMXBean sys)
|
private OperatingSystemMXBeanProvider(OperatingSystemMXBean sys)
|
||||||
throws ReflectiveOperationException {
|
throws ReflectiveOperationException {
|
||||||
this.sys = sys;
|
this.sys = sys;
|
||||||
getProcessCpuTime = sys.getClass().getMethod("getProcessCpuTime", new Class[] {});
|
getProcessCpuTime = sys.getClass().getMethod("getProcessCpuTime", new Class<?>[] {});
|
||||||
getProcessCpuTime.setAccessible(true);
|
getProcessCpuTime.setAccessible(true);
|
||||||
getOpenFileDescriptorCount =
|
getOpenFileDescriptorCount =
|
||||||
sys.getClass().getMethod("getOpenFileDescriptorCount", new Class[] {});
|
sys.getClass().getMethod("getOpenFileDescriptorCount", new Class<?>[] {});
|
||||||
getOpenFileDescriptorCount.setAccessible(true);
|
getOpenFileDescriptorCount.setAccessible(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user