Examples of UpdateSearchScope


Examples of org.eclipse.update.search.UpdateSearchScope

      return;

    try {

      /* Scope to RSSOwl Updates Only */
      UpdateSearchScope scope = new UpdateSearchScope();
      scope.addSearchSite("RSSOwl.org", new URL(UPDATE_SITE), null); //$NON-NLS-1$
      scope.setFeatureProvidedSitesEnabled(false);

      /* Run in Update Job */
      final UpdateJob job = new UpdateJob(Messages.FindUpdatesAction_UPDATE_SEARCH, true, false);
      job.getSearchRequest().setScope(scope);
      job.addJobChangeListener(new JobChangeAdapter() {
View Full Code Here

Examples of org.eclipse.update.search.UpdateSearchScope

      }
    });
  }

  UpdateSearchRequest getSearchRequest() {
    UpdateSearchScope scope = new UpdateSearchScope();

    /* Check for User Defined Sites from System Property */
    String extensionSites = System.getProperty(EXTENSION_SITES_PROPERTY);
    if (StringUtils.isSet(extensionSites)) {
      String[] sites = extensionSites.split(EXTENSION_SITES_DIVIDER);
      for (String site : sites) {
        try {
          URL url = new URL(site);
          scope.addSearchSite(url.toString(), url, null);
        } catch (MalformedURLException e) {
          // skip bad URLs
        }
      }
    }

    /* Add RSSOwl.org if user did not define any other sites */
    if (scope.getSearchSites().length == 0) {
      try {
        URL url = new URL(fFindTranslations ? NLS_UPDATE_SITE : UPDATE_SITE);
        scope.addSearchSite("RSSOwl.org", url, null); //$NON-NLS-1$
      } catch (MalformedURLException e) {
        // skip bad URLs
      }
    }

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.