コード例 #1
0
 /** @return this as a GeoJSON object. */
 @Override
 public JsonObject asGeoJSON(boolean isRoot) {
   JsonObject json = new JsonObject();
   json.addProperty("type", "Feature");
   if (mId != null) json.addProperty("id", mId);
   json.add("geometry", mGeometry.asGeoJSON());
   json.add("properties", geoJSONProperties());
   return json;
 }