Package org.jclouds.trmk.vcloud_0_8.domain.internal

Examples of org.jclouds.trmk.vcloud_0_8.domain.internal.CatalogItemImpl


      CatalogItem result = factory.create(
            injector.getInstance(CatalogItemHandler.class)).parse(is);
      assertEquals(
            result,
            new CatalogItemImpl(
                  "Windows Web Server 2008 R2 (64-bit)",
                  URI.create("https://services.vcloudexpress.terremark.com/api/v0.8/catalogItem/22"),
                  null,
                  new ReferenceTypeImpl(
                        "Compute Options",
View Full Code Here


   protected SortedMap<String, String> properties = Maps.newTreeMap();
   private ReferenceType customizationOptions;
   private ReferenceType computeOptions;

   public CatalogItem getResult() {
      return new CatalogItemImpl(catalogItem.getName(), catalogItem.getHref(), description, computeOptions,
            customizationOptions, entity, properties);
   }
View Full Code Here

                        ImmutableMap.<String, Map<String, ? extends org.jclouds.trmk.vcloud_0_8.domain.CatalogItem>> of(
                              CATALOG_REF.getName(),
                              ImmutableMap
                                    .<String, org.jclouds.trmk.vcloud_0_8.domain.CatalogItem> of(
                                          "template",
                                          new CatalogItemImpl(
                                                "template",
                                                URI.create("https://vcloud.safesecureweb.com/api/v0.8/catalogItem/2"),
                                                "description",
                                                new ReferenceTypeImpl(
                                                      "template",
View Full Code Here

                        ImmutableMap.<String, Map<String, ? extends org.jclouds.trmk.vcloud_0_8.domain.CatalogItem>> of(
                              CATALOG_REF.getName(),
                              ImmutableMap
                                    .<String, org.jclouds.trmk.vcloud_0_8.domain.CatalogItem> of(
                                          "template",
                                          new CatalogItemImpl(
                                                "template",
                                                URI.create("https://vcloud.safesecureweb.com/api/v0.8/catalogItem/2"),
                                                "description",
                                                new ReferenceTypeImpl(
                                                      "template",
View Full Code Here

      Task result = factory.create(injector.getInstance(TaskHandler.class)).parse(is);

      Task expects = new TaskImpl(URI.create("http://10.150.4.49/api/v0.8/task/23"), null, TaskStatus.ERROR,
            dateService.iso8601SecondsDateParse("2009-12-07T19:05:02Z"),
            dateService.iso8601SecondsDateParse("2009-12-10T14:40:32Z"), null, new ReferenceTypeImpl("testapp1",
                  TerremarkVCloudMediaType.VAPP_XML, URI.create("http://10.150.4.49/api/v0.8/vapp/1")), new ErrorImpl(
                  "Error processing job", 500, MinorCode.UNRECOGNIZED,
                  " Error in runDailySummaries date used:2009-12-09 19:40:30.577326+00:00", null));
      assertEquals(result, expects);

   }
View Full Code Here

   private ReferenceType ips;
   private ReferenceType extension;

   public Network getResult() {
      return new NetworkImpl(network.getName(), network.getType(), network.getHref(), description, gateway, netmask,
            fenceMode, extension, ips);
   }
View Full Code Here

      InputStream is = getClass().getResourceAsStream("/task.xml");

      Task result = factory.create(injector.getInstance(TaskHandler.class)).parse(is);
      Task expects = new TaskImpl(URI.create("https://services.vcloudexpress.terremark.com/api/v0.8/task/3299"), null,
            TaskStatus.SUCCESS, dateService.iso8601DateParse("2009-08-24T21:29:32.983Z"),
            dateService.iso8601DateParse("2009-08-24T21:29:44.65Z"), null, new ReferenceTypeImpl("Server1",
                  TerremarkVCloudMediaType.VAPP_XML,
                  URI.create("https://services.vcloudexpress.terremark.com/api/v0.8/vapp/4012")), null

      );
      assertEquals(result, expects);
View Full Code Here

      Task result = factory.create(injector.getInstance(TaskHandler.class)).parse(is);

      Task expects = new TaskImpl(URI.create("http://10.150.4.49/api/v0.8/task/23"), null, TaskStatus.ERROR,
            dateService.iso8601SecondsDateParse("2009-12-07T19:05:02Z"),
            dateService.iso8601SecondsDateParse("2009-12-10T14:40:32Z"), null, new ReferenceTypeImpl("testapp1",
                  TerremarkVCloudMediaType.VAPP_XML, URI.create("http://10.150.4.49/api/v0.8/vapp/1")), new ErrorImpl(
                  "Error processing job", 500, MinorCode.UNRECOGNIZED,
                  " Error in runDailySummaries date used:2009-12-09 19:40:30.577326+00:00", null));
      assertEquals(result, expects);
View Full Code Here

      VDC result = factory.create(injector.getInstance(VDCHandler.class)).parse(is);
      assertEquals(result.getName(), "Miami Environment 1");
      assertEquals(result.getHref(), URI.create("https://services.vcloudexpress.terremark.com/api/v0.8/vdc/32"));
      assertEquals(result.getResourceEntities(), ImmutableMap.<String, ReferenceType> of(
            "adriantest",
            new ReferenceTypeImpl("adriantest", TerremarkVCloudMediaType.VAPP_XML, URI
                  .create("https://services.vcloudexpress.terremark.com/api/v0.8/vapp/15124")),
            "centos-53",
            new ReferenceTypeImpl("centos-53", TerremarkVCloudMediaType.VAPP_XML, URI
                  .create("https://services.vcloudexpress.terremark.com/api/v0.8/vapp/15120"))));

      assertEquals(result.getAvailableNetworks(), ImmutableMap.of(
            "10.114.34.128/26",
            new ReferenceTypeImpl("10.114.34.128/26", "application/vnd.vmware.vcloud.network+xml", URI
                  .create("https://services.vcloudexpress.terremark.com/api/v0.8/network/1708"))));
      assertEquals(
            result.getCatalog(),
            new ReferenceTypeImpl("Miami Environment 1", CATALOG_XML, URI
                  .create("https://services.vcloudexpress.terremark.com/api/v0.8/vdc/32/catalog")));
      assertEquals(
            result.getPublicIps(),
            new ReferenceTypeImpl("Public IPs", "application/xml", URI
                  .create("https://services.vcloudexpress.terremark.com/api/v0.8/vdc/32/publicIps")));
      assertEquals(
            result.getInternetServices(),
            new ReferenceTypeImpl("Internet Services", "application/xml", URI
                  .create("https://services.vcloudexpress.terremark.com/api/v0.8/vdc/32/internetServices")));
   }
View Full Code Here

      InputStream is = getClass().getResourceAsStream("/instantiatedvapp.xml");

      VApp result = factory.create(injector.getInstance(VAppHandler.class)).parse(is);

      VApp expects = new VAppImpl("centos53", URI
               .create("http://10.150.4.49/api/v0.8/vApp/10"), Status.RESOLVED, 123456789l, new ReferenceTypeImpl(null,
               "application/vnd.vmware.vcloud.vdc+xml", URI.create("http://10.150.4.49/api/v0.8/vdc/4")),
               ImmutableListMultimap.<String, String> of(), null, null, null, ImmutableSet
                        .<ResourceAllocationSettingData> of());
      assertEquals(result, expects);
   }
View Full Code Here

TOP

Related Classes of org.jclouds.trmk.vcloud_0_8.domain.internal.CatalogItemImpl

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.