Package org.nasutekds.quicksetup.util

Examples of org.nasutekds.quicksetup.util.ZipExtractor


    notifyListeners(getLineBreak());

    try {

      if (Utils.isWebStart()) {
        ZipExtractor extractor;
        setCurrentProgressStep(UpgradeProgressStep.DOWNLOADING);

        try {
          LOG.log(Level.INFO, "Waiting for Java Web Start jar download");
          waitForLoader(UpgradeProgressStep.EXTRACTING.getProgress());
          LOG.log(Level.INFO, "Downloaded build file");
          String zipName = WebStartDownloader.getZipFileName();
          InputStream in =
                  Upgrader.class.getClassLoader().getResourceAsStream(zipName);
          extractor = new ZipExtractor(in,
              UpgradeProgressStep.EXTRACTING.getProgress(),
              UpgradeProgressStep.INITIALIZING.getProgress(),
              Utils.getNumberZipEntries(), zipName, this);

        } catch (ApplicationException e) {
          LOG.log(Level.SEVERE, "Error downloading Web Start jars", e);
          throw e;
        }
        notifyListeners(getFormattedDoneWithLineBreak());

        checkAbort();

        try {
          setCurrentProgressStep(UpgradeProgressStep.EXTRACTING);
          if (isVerbose())
          {
            notifyListeners(getLineBreak());
          }
          extractor.extract(getStageDirectory());
          if (!isVerbose())
          {
            notifyListeners(getFormattedDoneWithLineBreak());
          }
          else
View Full Code Here


      try {
        File buildFile = uud.getInstallPackage();
        if (buildFile != null) {
          LOG.log(Level.INFO, "Expanding zip file " + buildFile.getPath());
          File stageDirectory = initStageDirectory();
          ZipExtractor extractor = new ZipExtractor(buildFile);
          extractor.extract(stageDirectory);
          LOG.log(Level.INFO, "Extraction finished");
          Installation installation = new Installation(stageDirectory,
              stageDirectory);
          if (!installation.isValid(stageDirectory)) {
            LOG.log(Level.INFO, "Extraction produed an invalid NasuTekDS" +
View Full Code Here

    if (!initialized) {
      if (qsServerRoot.exists()) {
        stopServer();
        new FileManager().deleteRecursively(qsServerRoot);
      }
      ZipExtractor extractor = new ZipExtractor(getInstallPackageFile());
      extractor.extract(qsServerRoot);
      setupServer();
      initialized = true;
    }
  }
View Full Code Here

   * update properly the install progress ratio.
   * @throws ApplicationException if an error occurs.
   */
  private void extractZipFiles(InputStream is, int minRatio, int maxRatio)
      throws ApplicationException {
    ZipExtractor extractor =
            new ZipExtractor(is, minRatio, maxRatio,
            Utils.getNumberZipEntries(),
            getZipFileName(),
            this);
    extractor.extract(getUserData().getServerLocation());
  }
View Full Code Here

TOP

Related Classes of org.nasutekds.quicksetup.util.ZipExtractor

Copyright © 2018 www.massapicom. 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.