public static String getJavaagentLocation() { return LaunchingPlugin.getFileInPlugin(new Path("lib/javaagent-shaded.jar")).getAbsolutePath(); //$NON-NLS-1$ }
/** * Returns the system property string for the policy file * * @param workingDir the working directory * @return system property for the policy file */ public String getJavaPolicyFile(File workingDir) { File file = new File(workingDir, "java.policy.applet");//$NON-NLS-1$ if (!file.exists()) { // copy it to the working directory File test = LaunchingPlugin.getFileInPlugin(new Path("java.policy.applet")); //$NON-NLS-1$ try (BufferedOutputStream outputStream = new BufferedOutputStream(new FileOutputStream(file))) { byte[] bytes = getFileByteContent(test); outputStream.write(bytes); } catch (IOException e) { return "";//$NON-NLS-1$ } } return "-Djava.security.policy=java.policy.applet";//$NON-NLS-1$ }
/** * Returns the system property string for the policy file * * @param workingDir the working directory * @return system property for the policy file */ public String getJavaPolicyFile(File workingDir) { File file = new File(workingDir, "java.policy.applet");//$NON-NLS-1$ if (!file.exists()) { // copy it to the working directory File test = LaunchingPlugin.getFileInPlugin(new Path("java.policy.applet")); //$NON-NLS-1$ try (BufferedOutputStream outputStream = new BufferedOutputStream(new FileOutputStream(file))) { byte[] bytes = getFileByteContent(test); outputStream.write(bytes); } catch (IOException e) { return "";//$NON-NLS-1$ } } return "-Djava.security.policy=java.policy.applet";//$NON-NLS-1$ }
File file = LaunchingPlugin.getFileInPlugin(new Path("lib/launchingsupport.jar")); //$NON-NLS-1$ if (file != null && file.exists()) { String javaExecutablePath = javaExecutable.getAbsolutePath();
File file = LaunchingPlugin.getFileInPlugin(new Path("lib/launchingsupport.jar")); //$NON-NLS-1$ if (file != null && file.exists()) { String javaExecutablePath = javaExecutable.getAbsolutePath();
File file = LaunchingPlugin.getFileInPlugin(new Path("lib/launchingsupport.jar")); //$NON-NLS-1$ if (file != null && file.exists()) { VMRunnerConfiguration config = new VMRunnerConfiguration("org.eclipse.jdt.internal.launching.support.LegacySystemProperties", new String[] { file.getAbsolutePath() });//$NON-NLS-1$
File file = LaunchingPlugin.getFileInPlugin(new Path("lib/launchingsupport.jar")); //$NON-NLS-1$ if (file != null && file.exists()) { VMRunnerConfiguration config = new VMRunnerConfiguration("org.eclipse.jdt.internal.launching.support.LegacySystemProperties", new String[] { file.getAbsolutePath() });//$NON-NLS-1$