Package org.jclouds.json.internal

Examples of org.jclouds.json.internal.GsonWrapper


            .range(range)
            .build();
      assertThat(client.initiateJob(VAULT_NAME, retrieval)).isEqualTo(JOB_ID);

      RecordedRequest request = server.takeRequest();
      Json json = new GsonWrapper(new Gson());
      ArchiveRetrievalJobRequest job = json.fromJson(new String(request.getBody()), ArchiveRetrievalJobRequest.class);
      assertThat(job.getDescription()).isEqualTo(DESCRIPTION);
      assertThat(job.getRange()).isEqualTo(range);
      assertThat(job.getArchiveId()).isEqualTo(ARCHIVE_ID);
      assertThat(job.getType()).isEqualTo("archive-retrieval");
View Full Code Here


            .marker(marker)
            .build();
      assertThat(client.initiateJob(VAULT_NAME, job)).isEqualTo(JOB_ID);

      RecordedRequest request = server.takeRequest();
      Json json = new GsonWrapper(new Gson());
      job = json.fromJson(new String(request.getBody()), InventoryRetrievalJobRequest.class);
      assertThat(job.getFormat()).isEqualTo(format);
      assertThat(job.getParameters().getMarker()).isEqualTo(marker);
      assertThat(job.getParameters().getLimit()).isEqualTo(limit);
      assertThat(job.getParameters().getStartDate()).isEqualTo(startDate);
      assertThat(job.getParameters().getEndDate()).isEqualTo(endDate);
View Full Code Here

   private Binder binder;

   @BeforeGroups(groups = { "unit" })
   public void setup() {
      request = HttpRequest.builder().method("GET").endpoint("http://momma").build();
      Json json = new GsonWrapper(new Gson());
      binder = new ProductOrderToJson(json);
   }
View Full Code Here

   private Json json;

   @BeforeClass
   public void init() {
      json = new GsonWrapper(new Gson());
   }
View Full Code Here

   private Binder binder;

   @BeforeGroups(groups = { "unit" })
   public void setup() {
      request = HttpRequest.builder().method("GET").endpoint("http://momma").build();
      Json json = new GsonWrapper(new Gson());
      binder = new ProductOrderToJson(json);
   }
View Full Code Here

         "\"content_type\": \"application/unknown\"}]";

      InputStream stream = Strings2.toInputStream(jsonObjectList);

      ParseObjectInfoListFromJsonResponse parser =
         new ParseObjectInfoListFromJsonResponse(new GsonWrapper(new Gson()));

      GeneratedHttpRequest.Builder builder = new GeneratedHttpRequest.Builder();
      builder.method("method")
             .endpoint("http://test.org/test")
             .invocation(Invocation.create(Invokable.from(Object.class.getMethod("toString", null)),
View Full Code Here

   private Json json;

   @BeforeClass
   public void init() {
      json = new GsonWrapper(new Gson());
   }
View Full Code Here

   private Json json;

   @BeforeClass
   public void init() {
      json = new GsonWrapper(new Gson());
   }
View Full Code Here

TOP

Related Classes of org.jclouds.json.internal.GsonWrapper

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.