Удалены устаревшие методы

This commit is contained in:
Gravit 2018-10-22 18:53:01 +07:00
parent ec3a1d9bb0
commit 4c629fb930
No known key found for this signature in database
GPG key ID: 061981E1E85D3216
3 changed files with 5 additions and 18 deletions

View file

@ -151,6 +151,7 @@ public static void main(String... args) throws Throwable {
JVMHelper.checkStackTrace(LauncherEngine.class); JVMHelper.checkStackTrace(LauncherEngine.class);
JVMHelper.verifySystemProperties(Launcher.class, true); JVMHelper.verifySystemProperties(Launcher.class, true);
EnvHelper.checkDangerousParametrs(); EnvHelper.checkDangerousParametrs();
if(!LauncherAgent.isStarted()) throw new SecurityException("JavaAgent not set");
LogHelper.printVersion("Launcher"); LogHelper.printVersion("Launcher");
// Start Launcher // Start Launcher
Instant start = Instant.now(); Instant start = Instant.now();

View file

@ -50,4 +50,8 @@ public static void premain(String agentArgument, Instrumentation instrumentation
} }
} }
} }
public static boolean isStarted()
{
return isAgentStarted;
}
} }

View file

@ -71,18 +71,6 @@ public static OS byName(String name) {
} }
} }
@Deprecated
public static void addClassPath(URL url) {
throw new IllegalArgumentException("Method Deprecated");
}
@Deprecated
public static void addNativePath(Path path) {
throw new IllegalArgumentException("Method Deprecated");
}
public static void appendVars(ProcessBuilder builder, Map<String, String> vars) { public static void appendVars(ProcessBuilder builder, Map<String, String> vars) {
builder.environment().putAll(vars); builder.environment().putAll(vars);
@ -106,12 +94,6 @@ public static void fullGC() {
LogHelper.debug("Used heap: %d MiB", RUNTIME.totalMemory() - RUNTIME.freeMemory() >> 20); LogHelper.debug("Used heap: %d MiB", RUNTIME.totalMemory() - RUNTIME.freeMemory() >> 20);
} }
@Deprecated
public static Certificate[] getCertificates(String resource) {
throw new IllegalArgumentException("Method Deprecated");
}
public static String[] getClassPath() { public static String[] getClassPath() {
return System.getProperty("java.class.path").split(File.pathSeparator); return System.getProperty("java.class.path").split(File.pathSeparator);