Package uk.co.brunella.osgi.bdt.repository

Examples of uk.co.brunella.osgi.bdt.repository.BundleRepositoryPersister.load()


      if (!repositoryDirectory.exists() || !repositoryDirectory.isDirectory()) {
        throw new InitializationError("Repository " + repositoryDirectory + " does not exist or is not a directory");
      }
      BundleRepositoryPersister persister = new BundleRepositoryPersister(repositoryDirectory);
      try {
        repositories.add(persister.load());
      } catch (IOException e) {
        List<Throwable> list = new ArrayList<Throwable>(1);
        list.add(e);
        throw new InitializationError(list);
      }
View Full Code Here


    if (!checkRepository(repositoryDirectory)) {
      return false;
    }
    VersionRange versionRange = VersionRange.parseVersionRange(range);
    BundleRepositoryPersister persister = new BundleRepositoryPersister(repositoryDirectory);
    BundleRepository repository = persister.load();
   
    ExportPackage[] exportPackages = repository.resolve(packageName, versionRange, true);
    if (exportPackages.length == 0) {
      System.out.println("No match found");
    } else {
View Full Code Here

  }

  public void setRepositoryDirectory(String repositoryDirectory) {
    BundleRepositoryPersister persister = new BundleRepositoryPersister(new File(repositoryDirectory));
    try {
      repository = persister.load();
    } catch (IOException e) {
      throw new RuntimeException(e);
    }
  }
 
View Full Code Here

  }

  private void loadRepository(String repositoryLocation) throws IOException {
    BundleRepositoryPersister persister = new BundleRepositoryPersister(new File(repositoryLocation));
    repository = persister.load();
  }

  private File findBundle(String bundleName) {
    String name;
    VersionRange versionRange;
View Full Code Here

    log("Resolve classpath", Project.MSG_VERBOSE);
    isResolved = true;
    BundleRepositoryPersister persister = new BundleRepositoryPersister(repositoryDirectory);
    BundleRepository repository = null;
    try {
      repository = persister.load();
    } catch (IOException e) {
      // cannot load repository - create an empty one
      log("Repository " + repositoryDirectory + " cannot be loaded", Project.MSG_WARN);
      repository = new BundleRepository("J2SE-1.5");
    }
View Full Code Here

//    }
  }

  private void loadRepository(String repositoryLocation) throws IOException {
    BundleRepositoryPersister persister = new BundleRepositoryPersister(new File(repositoryLocation));
    repository = persister.load();
  }

  private Class<?> loadTestClass(Parse cells, String testClassName) {
    List<URL> jarUrls = new ArrayList<URL>();
    try {
View Full Code Here

      String[] repositoryPaths = getRepositoryPaths();
      for (int i = 0; i < repositoryPaths.length; i++) {
        BundleRepositoryPersister persister = new BundleRepositoryPersister(new File(repositoryPaths[i]));
        BundleRepository repository = null;
        try {
          repository = persister.load();
        } catch (IOException e) {
          repository = null;
        }
        invisibleRoot.addChild(createTreeParent(repository, repositoryPaths[i]));
      }
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.