Package org.apache.felix.bundlerepository

Examples of org.apache.felix.bundlerepository.Repository


     return result;
   }
 
   private Repository getLocalRepository(RepositoryAdmin admin)
   {
       Repository localRepository = repositoryAdmin.getLocalRepository();
      
       Resource[] resources = localRepository.getResources();

       Resource[] newResources = new Resource[resources.length];
       for (int i = 0; i < resources.length; i++) {
           newResources[i] = new ResourceWrapper(resources[i]);
       }
View Full Code Here


  private Resolver getConfiguredObrResolver(String appName, String appVersion,
      Collection<ModelledResource> byValueBundles, boolean noExtraRepositories) throws ResolverException
  {
    log.debug(LOG_ENTRY, "getConfiguredObrResolver", new Object[]{appName, appVersion,byValueBundles });
    DataModelHelper helper = repositoryAdmin.getHelper();
    Repository appRepo;
    try {     
      ByteArrayOutputStream bytesOut = new ByteArrayOutputStream();
      RepositoryGeneratorImpl.generateRepository(repositoryAdmin, appName + "_" + appVersion, byValueBundles, bytesOut);
      appRepo = helper.readRepository(new InputStreamReader(new ByteArrayInputStream(bytesOut.toByteArray())));
    } catch (Exception e) {
View Full Code Here

        for (URI uri : uris) {
          InputStream is = null;
          try {
            is = uri.toURL().openStream();
            Reader repoReader = new InputStreamReader(is);
            Repository aPlatformRepo = helper.readRepository(repoReader);
            Resource resources[] = aPlatformRepo.getResources();
            for (Resource r : resources) {
              Capability[] caps = r.getCapabilities();
              for (Capability c : caps) {
                obrResolver.addGlobalCapability(c);
              }
View Full Code Here

     return result;
   }
 
   private Repository getLocalRepository(RepositoryAdmin admin)
   {
       Repository localRepository = repositoryAdmin.getLocalRepository();
      
       Resource[] resources = localRepository.getResources();

       Resource[] newResources = new Resource[resources.length];
       for (int i = 0; i < resources.length; i++) {
           newResources[i] = new ResourceWrapper(resources[i]);
       }
View Full Code Here

                reqs.add(req);
                infos.put(req, bundleInfo);
            }
        }

        Repository repository = repositoryAdmin.getHelper().repository(ress.toArray(new Resource[ress.size()]));
        List<Repository> repos = new ArrayList<Repository>();
        repos.add(repositoryAdmin.getSystemRepository());
        repos.add(repositoryAdmin.getLocalRepository());
        repos.add(repository);
        repos.addAll(Arrays.asList(repositoryAdmin.listRepositories()));
View Full Code Here

        String appName = appMeta.getApplicationSymbolicName();
        Version appVersion = appMeta.getApplicationVersion();
        List<Content> appContent = appMeta.getApplicationContents();

        Repository appRepository = null;

        try {
            Document doc = RepositoryDescriptorGenerator.generateRepositoryDescriptor(appName + "_"
                                                                                      + appVersion,
                    app.getBundleInfo());
View Full Code Here

              ress.add(res);
              infos.put(res, bundleInfo);
            }
        }

        Repository repository = repositoryAdmin.getHelper().repository(ress.toArray(new Resource[ress.size()]));
        List<Repository> repos = new ArrayList<Repository>();
        repos.add(repositoryAdmin.getSystemRepository());
        repos.add(repositoryAdmin.getLocalRepository());
        repos.add(repository);
        repos.addAll(Arrays.asList(repositoryAdmin.listRepositories()));
View Full Code Here

              ress.add(res);
              infos.put(res, bundleInfo);
            }
        }

        Repository repository = repositoryAdmin.getHelper().repository(ress.toArray(new Resource[ress.size()]));
        List<Repository> repos = new ArrayList<Repository>();
        repos.add(repositoryAdmin.getSystemRepository());
        repos.add(repositoryAdmin.getLocalRepository());
        repos.add(repository);
        repos.addAll(Arrays.asList(repositoryAdmin.listRepositories()));
View Full Code Here

        String appName = appMeta.getApplicationSymbolicName();
        Version appVersion = appMeta.getApplicationVersion();
        List<Content> appContent = appMeta.getApplicationContents();

        Repository appRepo;

        try {
            Document doc = RepositoryDescriptorGenerator.generateRepositoryDescriptor(appName + "_" + appVersion, app
                    .getBundleInfo());
View Full Code Here

            throw re;
        }
    }

    private Repository getLocalRepository(RepositoryAdmin admin) {
        Repository localRepository = repositoryAdmin.getLocalRepository();

        Resource[] resources = localRepository.getResources();

        Resource[] newResources = new Resource[resources.length];
        for (int i = 0; i < resources.length; i++) {
            newResources[i] = new ResourceWrapper(resources[i]);
        }
View Full Code Here

TOP

Related Classes of org.apache.felix.bundlerepository.Repository

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.