@Override
    public Set<JavaPlatform> instantiate() throws IOException {
        //TODO: Download (in background?)
        String downloadedFolder = (String) wizard.getProperty(DiscoPlatformIt.PROP_DOWNLOAD);
        if (downloadedFolder != null) {
            File f = new File(downloadedFolder);
            if (!f.isDirectory()) {
                //open the file manager for the parent folder
                Desktop.getDesktop().open(f.getParentFile());
                return Collections.EMPTY_SET;
            }
            String name = state.selection.getJavaPlatformDisplayName();
            return Collections.singleton(J2SEPlatformUtils.register(new File(downloadedFolder), name));
        } else {
            //TODO: notifcation?
            return Collections.EMPTY_SET;
        }
    }
@Override
    public Set<JavaPlatform> instantiate() throws IOException {
       
        String downloadedFolder = (String) wizard.getProperty(DiscoPlatformIt.PROP_DOWNLOAD);
        if (downloadedFolder != null) {
            File f = new File(downloadedFolder);
            if (!f.isDirectory()) {
               
                Desktop.getDesktop().open(f.getParentFile());
                return Collections.EMPTY_SET;
            }
            String name = state.selection.getJavaPlatformDisplayName();
            return Collections.singleton(J2SEPlatformUtils.register(new File(downloadedFolder), name));
        } else {
           
            return Collections.EMPTY_SET;
        }
    }
@override public set<javaplatform> instantiate() throws ioexception { string downloadedfolder = (string) wizard.getproperty(discoplatformit.prop_download); if (downloadedfolder != null) { file f = new file(downloadedfolder); if (!f.isdirectory()) { desktop.getdesktop().open(f.getparentfile()); return collections.empty_set; } string name = state.selection.getjavaplatformdisplayname(); return collections.singleton(j2seplatformutils.register(new file(downloadedfolder), name)); } else { return collections.empty_set; } }