Package com.google.greaze.definition

Examples of com.google.greaze.definition.UrlParamsSpec$Builder


    int value = (Integer) UrlParamsExtractor.parseUrlParamValue("1", Integer.class, gson);
    assertEquals(1, value);
  }

  public void testUrlParams() {
    UrlParamsSpec spec = new UrlParamsSpec.Builder()
      .put("key1", String.class)
      .put("key2", Integer.class)
      .put("key3", Integer.class)
      .put("key4", Boolean.class)
      .build();
View Full Code Here


  }

  @SuppressWarnings("rawtypes")
  public void testUrlParamsUntypedValue() {
    TypeVariable typeVariableType = GenericType.getTypeVariableType();
    UrlParamsSpec spec = new UrlParamsSpec.Builder()
      .put("key1", String.class)
      .put("key2", Object.class)
      .put("key3", typeVariableType)
      .build();
    UrlParamsExtractor extractor = new UrlParamsExtractor(spec, gson);
View Full Code Here

    assertEquals("2", map.get("key2"));
    assertEquals("bar", map.get("key3"));
  }

  public void testUrlParamsWithParamsObject() {
    UrlParamsSpec spec = new UrlParamsSpec.Builder()
      .put("key1", String.class)
      .setType(MySelectionFields.class)
      .put("key2", Integer.class)
      .build();
    UrlParamsExtractor extractor = new UrlParamsExtractor(spec, gson);
View Full Code Here

TOP

Related Classes of com.google.greaze.definition.UrlParamsSpec$Builder

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.