Examples of download()


Examples of net.schmizz.sshj.xfer.scp.SCPFileTransfer.download()

      String timeStampedServiceName = GFacUtils.createUniqueNameForService(jobExecutionContext.getServiceName());
      File localStdOutFile = File.createTempFile(timeStampedServiceName, "stdout");
      File localStdErrFile = File.createTempFile(timeStampedServiceName, "stderr");

      SCPFileTransfer fileTransfer = securityContext.getSSHClient().newSCPFileTransfer();
      fileTransfer.download(app.getStandardOutput(), localStdOutFile.getAbsolutePath());
      fileTransfer.download(app.getStandardError(), localStdErrFile.getAbsolutePath());

      String stdOutStr = GFacUtils.readFileToString(localStdOutFile.getAbsolutePath());
      String stdErrStr = GFacUtils.readFileToString(localStdErrFile.getAbsolutePath());
       Map<String, ActualParameter> stringMap = new HashMap<String, ActualParameter>();
View Full Code Here

Examples of net.schmizz.sshj.xfer.scp.SCPFileTransfer.download()

      File localStdOutFile = File.createTempFile(timeStampedServiceName, "stdout");
      File localStdErrFile = File.createTempFile(timeStampedServiceName, "stderr");

      SCPFileTransfer fileTransfer = securityContext.getSSHClient().newSCPFileTransfer();
      fileTransfer.download(app.getStandardOutput(), localStdOutFile.getAbsolutePath());
      fileTransfer.download(app.getStandardError(), localStdErrFile.getAbsolutePath());

      String stdOutStr = GFacUtils.readFileToString(localStdOutFile.getAbsolutePath());
      String stdErrStr = GFacUtils.readFileToString(localStdErrFile.getAbsolutePath());
       Map<String, ActualParameter> stringMap = new HashMap<String, ActualParameter>();
View Full Code Here

Examples of net.sf.jabref.external.DownloadExternalFile.download()

                    bibtexKey = entry.getCiteKey();
                }
            }
            DownloadExternalFile def = new DownloadExternalFile(frame, metaData, bibtexKey);
            try {
                def.download(this);
            } catch (IOException ex) {
                ex.printStackTrace();
            }
        }
View Full Code Here

Examples of net.sf.jabref.net.URLDownload.download()

          URL url = new URL(res);

          URLDownload udl = new URLDownload(parent, url, file);
          try {
            udl.download();
          } catch (IOException e2) {
            JOptionPane.showMessageDialog(parent, Globals.lang("Invalid URL")+": "
              + e2.getMessage(), Globals.lang("Download file"),
              JOptionPane.ERROR_MESSAGE);
            Globals.logger("Error while downloading " + url.toString());
View Full Code Here

Examples of net.sf.jabref.net.URLDownload.download()

    public void installFromURL(URL url) {
        try {
            File tmpFile = File.createTempFile("jabref-plugin", ".jar");
            tmpFile.deleteOnExit();
            URLDownload ud = new URLDownload(frame, url, tmpFile);
            ud.download();
            String path = url.getPath();
            int pos = path.lastIndexOf('/');
            if ((pos >= 0) && (pos < path.length()-1))
                path = path.substring(pos+1);
            PluginInstaller.installPlugin(frame, tmpFile, path);
View Full Code Here

Examples of net.sf.jabref.net.URLDownload.download()

    }
   
    public void run() {
        URLDownload ud = new URLDownload(parent, resource, destination);
        try {
            ud.download();
        } catch (IOException ex) {
            Globals.logger("Error extracting resource: "+ex.getMessage());           
        }
    }
}
View Full Code Here

Examples of net.sf.jabref.net.URLDownload.download()

        }
        File destFile = new File(PluginCore.userPluginDir, destFileName);
        URLDownload ud = new URLDownload(frame, source, destFile);

        try {
            ud.download();
            return SUCCESS;
        } catch (IOException e) {
            e.printStackTrace();
            return UNABLE_TO_COPY_FILE;
        }
View Full Code Here

Examples of net.sf.jabref.net.URLDownload.download()

    }

    protected String getCitationsFromUrl(String urlQuery, List<String> ids) throws IOException {
        URL url = new URL(urlQuery);
        URLDownload ud = new URLDownload(url);
        ud.download();

        String cont = ud.getStringContent();
        String entirePage = cont;

        Matcher m = idPattern.matcher(cont);
View Full Code Here

Examples of net.sf.jabref.net.URLDownload.download()

                        null, JFileChooser.SAVE_DIALOG, false);
                if (toName == null)
                    return;
                else toFile = new File(toName);
                URLDownload ud = new URLDownload(comp, url, toFile);
                ud.download();
                comp.setText(toFile.getPath());
            } catch (MalformedURLException ex) {
                ex.printStackTrace()//To change body of catch statement use File | Settings | File Templates.
            } catch (IOException ex2) {
                ex2.printStackTrace()//To change body of catch statement use File | Settings | File Templates.
View Full Code Here

Examples of net.sf.jabref.net.URLDownload.download()

            entryUrl = entryUrl.replaceAll("%", "%25").replaceAll(":", "%3A").replaceAll("/", "%2F")
                    .replaceAll("\\?", "%3F").replaceAll("&", "%26").replaceAll("=", "%3D");
                   
            URL url = new URL(BIBSONOMY_SCRAPER+entryUrl+BIBSONOMY_SCRAPER_POST);
            URLDownload ud = new URLDownload(url);
            ud.download();
            String bibtex = ud.getStringContent();
            BibtexParser bp = new BibtexParser(new StringReader(bibtex));
            ParserResult pr = bp.parse();
            if ((pr != null) && (pr.getDatabase().getEntryCount() > 0)) {
                return pr.getDatabase().getEntries().iterator().next();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.