Package org.jclouds.karaf.commands.table

Examples of org.jclouds.karaf.commands.table.ShellTable.display()


    }

    protected void printCookbooks(ChefService service, Iterable<? extends CookbookVersion> cookbookVersions, PrintStream out) {
        ShellTable table = shellTableFactory.build("cookbook");
        table.setDisplayData(cookbookVersions);
        table.display(out, true, true);

        for (CookbookVersion cookbookVersion : cookbookVersions) {
            for (String cacheKey : ServiceHelper.findCacheKeysForService(service)) {
                cacheProvider.getProviderCacheForType(ChefConstants.COOKBOOK_CACHE).putAll(cacheKey, cookbookVersion.getMetadata().getProviding().keySet());
            }
View Full Code Here


   }

   protected void printNodes(ComputeService service, Set<? extends ComputeMetadata> nodes, PrintStream out) {
     ShellTable table = shellTableFactory.build("node");
     table.setDisplayData(nodes);
     table.display(out, true, true);

      for (ComputeMetadata metadata : nodes) {
         NodeMetadata node = (NodeMetadata) metadata;
        for (String cacheKey : ServiceHelper.findCacheKeysForService(service)) {
          cacheProvider.getProviderCacheForType(Constants.GROUP).put(cacheKey, node.getGroup());
View Full Code Here

   }

   protected void printHardwares(ComputeService service, Set<? extends Hardware> hardwares, PrintStream out) {
     ShellTable table = shellTableFactory.build("hardware");
     table.setDisplayData(hardwares);
     table.display(out, true, true);

      for (Hardware hardware : hardwares) {
         for (String cacheKey : ServiceHelper.findCacheKeysForService(service)) {
           cacheProvider.getProviderCacheForType(Constants.HARDWARE_CACHE).put(cacheKey, hardware.getId());
         }
View Full Code Here

   }

   protected void printImages(ComputeService service, Set<? extends Image> images, PrintStream out) {
      ShellTable table = shellTableFactory.build("image");
      table.setDisplayData(images);
      table.display(out, true, true);

      for (Image image : images) {
        for (String cacheKey : ServiceHelper.findCacheKeysForService(service)) {
         cacheProvider.getProviderCacheForType(Constants.IMAGE_CACHE).put(cacheKey, image.getId());
        }
View Full Code Here

   }

   protected void printLocations(ComputeService computeService, PrintStream out) {
     ShellTable table = shellTableFactory.build("location");
     table.setDisplayData(getAllLocations(computeService));
     table.display(out, true, true);
   }

   protected Set<? extends Location> getAllLocations(ComputeService computeService) {
      Set<Location> all = new HashSet<Location>();
      for (Location loc : computeService.listAssignableLocations()) {
View Full Code Here

   }

   protected void printNodes(ComputeService service, Set<? extends ComputeMetadata> nodes, PrintStream out) {
     ShellTable table = shellTableFactory.build("node");
     table.setDisplayData(nodes);
     table.display(out, true, true);

      for (ComputeMetadata metadata : nodes) {
         NodeMetadata node = (NodeMetadata) metadata;
        for (String cacheKey : ServiceHelper.findCacheKeysForService(service)) {
          cacheProvider.getProviderCacheForType(Constants.GROUP).put(cacheKey, node.getGroup());
View Full Code Here

   }

   protected void printHardwares(ComputeService service, Set<? extends Hardware> hardwares, PrintStream out) {
     ShellTable table = shellTableFactory.build("hardware");
     table.setDisplayData(hardwares);
     table.display(out, true, true);

      for (Hardware hardware : hardwares) {
         for (String cacheKey : ServiceHelper.findCacheKeysForService(service)) {
           cacheProvider.getProviderCacheForType(Constants.HARDWARE_CACHE).put(cacheKey, hardware.getId());
         }
View Full Code Here

   }

   protected void printImages(ComputeService service, Set<? extends Image> images, PrintStream out) {
      ShellTable table = shellTableFactory.build("image");
      table.setDisplayData(images);
      table.display(out, true, true);

      for (Image image : images) {
        for (String cacheKey : ServiceHelper.findCacheKeysForService(service)) {
         cacheProvider.getProviderCacheForType(Constants.IMAGE_CACHE).put(cacheKey, image.getId());
        }
View Full Code Here

   }

   protected void printLocations(ComputeService computeService, PrintStream out) {
     ShellTable table = shellTableFactory.build("location");
     table.setDisplayData(getAllLocations(computeService));
     table.display(out, true, true);
   }

   protected Set<? extends Location> getAllLocations(ComputeService computeService) {
      Set<Location> all = new HashSet<Location>();
      for (Location loc : computeService.listAssignableLocations()) {
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.