Examples of VLANInfo


Examples of org.jclouds.cloudsigma.domain.VLANInfo

      drive = drive2;
   }

   @Test
   public void testCreateAndDestroyVLAN() throws Exception {
      VLANInfo vlan = client.createVLAN(prefix);
      String id = vlan.getUuid();
      try {
         vlan = client.getVLANInfo(vlan.getUuid());
         assertEquals(vlan.getName(), prefix);

         String prefix2 = prefix + "2";
         vlan = client.renameVLAN(vlan.getUuid(), prefix2);
         assertEquals(vlan.getName(), prefix2);
      } finally {
         client.destroyVLAN(id);
      }
   }
View Full Code Here

Examples of org.jclouds.cloudsigma.domain.VLANInfo

      drive = drive2;
   }

   @Test
   public void testCreateAndDestroyVLAN() throws Exception {
      VLANInfo vlan = client.createVLAN(prefix);
      String id = vlan.getUuid();
      try {
         vlan = client.getVLANInfo(vlan.getUuid());
         assertEquals(vlan.getName(), prefix);

         String prefix2 = prefix + "2";
         vlan = client.renameVLAN(vlan.getUuid(), prefix2);
         assertEquals(vlan.getName(), prefix2);
      } finally {
         client.destroyVLAN(id);
      }
   }
View Full Code Here

Examples of org.jclouds.cloudsigma.domain.VLANInfo

      drive = drive2;
   }

   @Test
   public void testCreateAndDestroyVLAN() throws Exception {
      VLANInfo vlan = client.createVLAN(prefix);
      String id = vlan.getUuid();
      try {
         vlan = client.getVLANInfo(vlan.getUuid());
         assertEquals(vlan.getName(), prefix);

         String prefix2 = prefix + "2";
         vlan = client.renameVLAN(vlan.getUuid(), prefix2);
         assertEquals(vlan.getName(), prefix2);
      } finally {
         client.destroyVLAN(id);
      }
   }
View Full Code Here

Examples of org.jclouds.cloudsigma.domain.VLANInfo

      drive = drive2;
   }

   @Test
   public void testCreateAndDestroyVLAN() throws Exception {
      VLANInfo vlan = client.createVLAN(prefix);
      String id = vlan.getUuid();
      try {
         vlan = client.getVLANInfo(vlan.getUuid());
         assertEquals(vlan.getName(), prefix);

         String prefix2 = prefix + "2";
         vlan = client.renameVLAN(vlan.getUuid(), prefix2);
         assertEquals(vlan.getName(), prefix2);
      } finally {
         client.destroyVLAN(id);
      }
   }
View Full Code Here

Examples of org.jclouds.cloudsigma2.domain.VLANInfo

   }

   @Override
   public <R extends HttpRequest> R bindToRequest(R request, Object input) {
      checkArgument(input instanceof VLANInfo, "this binder is only valid for VLANInfo!");
      VLANInfo create = VLANInfo.class.cast(input);
      JsonObject vlanJsonObject = vlanInfoJsonObjectFunction.apply(create);

      request.setPayload(vlanJsonObject.toString());
      request.getPayload().getContentMetadata().setContentType(MediaType.APPLICATION_JSON);
      return request;
View Full Code Here

Examples of org.jclouds.cloudsigma2.domain.VLANInfo

   @Test
   public void testEditVLAN() throws Exception {
      Map<String, String> meta = Maps.newHashMap();
      meta.put("test", "test data");

      VLANInfo vlanInfo = new VLANInfo.Builder()
            .meta(meta)
            .build();

      if (api.listVLANs().size() > 0) {
         checkVlAN(vlanInfo, api.editVLAN(api.listVLANs().concat().get(0).getUuid(), vlanInfo));
View Full Code Here

Examples of org.jclouds.cloudsigma2.domain.VLANInfo

                  .build(),
            responseBuilder()
                  .payload(payloadFromResourceWithContentType("/vlan-single.json", MediaType.APPLICATION_JSON))
                  .build());

      VLANInfo result = api.getVLANInfo(uuid);
      assertNotNull(result);
   }
View Full Code Here

Examples of org.jclouds.cloudsigma2.domain.VLANInfo

                  .build(),
            responseBuilder()
                  .payload(payloadFromResourceWithContentType("/vlan-single.json", MediaType.APPLICATION_JSON))
                  .build());

      VLANInfo result = api.editVLAN(uuid, new VLANInfo.Builder().meta(meta).build());
      assertNotNull(result);
   }
View Full Code Here

Examples of org.jclouds.cloudsigma2.domain.VLANInfo

   @Test
   public void testEditVLAN() throws Exception {
      Map<String, String> meta = Maps.newHashMap();
      meta.put("test", "test data");

      VLANInfo vlanInfo = new VLANInfo.Builder()
            .meta(meta)
            .build();

      if (api.listVLANs().size() > 0) {
         checkVlAN(vlanInfo, api.editVLAN(api.listVLANs().concat().get(0).getUuid(), vlanInfo));
View Full Code Here

Examples of org.jclouds.cloudsigma2.domain.VLANInfo

                  .build(),
            responseBuilder()
                  .payload(payloadFromResourceWithContentType("/vlan-single.json", MediaType.APPLICATION_JSON))
                  .build());

      VLANInfo result = api.getVLANInfo(uuid);
      assertNotNull(result);
   }
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.