Package com.simplegeo.client.types

Examples of com.simplegeo.client.types.Feature


  @Test
  public void testAddUpdateDeletePlaceSync() {
    try {
      JSONObject origJson = new JSONObject(TestEnvironment.getJsonPointStringNoId());
      Feature feature = Feature.fromJSON(origJson);
      String jsonString = client.addPlace(feature);
      JSONObject json = new JSONObject(jsonString);
     
      Assert.assertNotNull(json.get("id"));
      String newPlaceHandle = json.getString("id");
     
      feature = Feature.fromJSON(origJson);
      feature.setSimpleGeoId(newPlaceHandle);
      jsonString = client.updatePlace(feature);
     
      Assert.assertNotNull(json.get("id"));
      Assert.assertEquals(newPlaceHandle, json.getString("id"));
     
View Full Code Here

TOP

Related Classes of com.simplegeo.client.types.Feature

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.