Package org.jclouds.vcloud.director.v1_5.domain

Examples of org.jclouds.vcloud.director.v1_5.domain.AdminCatalog


            .httpRequestBuilder().build(),
         new VcloudHttpResponsePrimer()
            .xmlFilePayload("/vApp/modifiedVapp.xml", VCloudDirectorMediaType.VAPP)
            .httpResponseBuilder().build());

    VApp modified = getVApp();
    modified.setName("new-name");
    modified.setDescription("New Description");

    Task expected = editVAppTask();

    assertEquals(api.getVAppApi().edit(vAppURI, modified), expected);
   }
View Full Code Here


    assertEquals(api.getVAppApi().editStartupSection(vAppURI, section), expected);
   }

   public static VApp getVApp() {
      // FIXME Does not match XML
      VApp vApp = VApp.builder()
            .href(URI.create("https://mycloud.greenhousedata.com/api/vApp/vapp-d0e2b6b9-4381-4ddc-9572-cdfae54059be"))
//            .link(Link.builder()
//                     .href(URI.create())
//                     .build())
            .build();
View Full Code Here

      cleanUpVAppTemplateInOrg();
   }

   @Test(description = "GET /query")
   public void testQuery() {
      VAppTemplate vAppTemplate = lazyGetVAppTemplate();
      QueryResultRecords queryResult = queryApi
               .query("vAppTemplate", String.format("name==%s", vAppTemplate.getName()));
      Set<URI> hrefs = toHrefs(queryResult);

      assertRecordTypes(queryResult, Arrays.asList(VCloudDirectorMediaType.VAPP_TEMPLATE, null),
               QueryResultVAppTemplateRecord.class);
      assertTrue(hrefs.contains(vAppTemplate.getHref()), "VAppTemplates query result should include vAppTemplate "
               + vAppTemplate.getHref() + "; but only has " + hrefs);
   }
View Full Code Here

               + lazyGetVAppTemplate().getHref() + "; but only has " + hrefs);
   }

   @Test(description = "GET /vAppTemplates/query?filter")
   public void testQueryVAppTemplatesWithFilter() {
      VAppTemplate vAppTemplate = lazyGetVAppTemplate();
      QueryResultRecords queryResult = queryApi.vAppTemplatesQuery(String.format("name==%s", vAppTemplate.getName()));
      Set<URI> hrefs = toHrefs(queryResult);

      assertRecordTypes(queryResult, Arrays.asList(VCloudDirectorMediaType.VAPP_TEMPLATE, null),
               QueryResultVAppTemplateRecord.class);
      assertTrue(hrefs.contains(vAppTemplate.getHref()), "VAppTemplates query result should have found vAppTemplate "
               + vAppTemplate.getHref());
   }
View Full Code Here

      return task;
   }

   public static VmPendingQuestion getPendingQuestion() {
      VmPendingQuestion question = VmPendingQuestion.builder()
            .build();

      return question;
   }
View Full Code Here

      return question;
   }

   public static VmQuestionAnswer answerQuestion() {
      VmQuestionAnswer answer = null; // = VmQuestionAnswer.builder()
//            .build();

      return answer;
   }
View Full Code Here

      return task;
   }

   public static RasdItem getVirtualHardwareSectionCpu() {
      RasdItem cpu = RasdItem.builder()
            .build();

      return cpu;
   }
View Full Code Here

      return media;
   }

   public static RasdItem getVirtualHardwareSectionMemory() {
      RasdItem memory = RasdItem.builder()
            .build();

      return memory;
   }
View Full Code Here

               .apiCommand("GET", "/admin/org/6f312e42-cd2b-488d-a2bb-97519cd57ed0").acceptAnyMedia()
               .httpRequestBuilder().build(),
               new VcloudHttpResponsePrimer().xmlFilePayload("/org/admin/org.xml", VCloudDirectorMediaType.ADMIN_ORG)
                        .httpResponseBuilder().build());

      AdminOrg expected = adminOrg();

      assertEquals(api.getOrgApi().get(orgRef.getHref()), expected);
   }
View Full Code Here

                        .acceptAnyMedia().httpRequestBuilder().build(),
               new VcloudHttpResponsePrimer()
                        .xmlFilePayload("/org/admin/emailSettings.xml", VCloudDirectorMediaType.ORG_GENERAL_SETTINGS)
                        .httpResponseBuilder().build());

      OrgEmailSettings expected = emailSettings();

      assertEquals(api.getOrgApi().getEmailSettings(orgRef.getHref()), expected);
   }
View Full Code Here

TOP

Related Classes of org.jclouds.vcloud.director.v1_5.domain.AdminCatalog

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.