我需要{"location":{"lat": 50.4, "lng": 30.5}}
在服务器上发送
我这样做
List<NameValuePair> nameValuePairs = new ArrayList<NameValuePair>(1);
List<NameValuePair> gps = new ArrayList<NameValuePair>(2);
gps.add(new BasicNameValuePair("lat", Util
.getLatitude()));
gps.add(new BasicNameValuePair("lng", Util
.getLatitude()));
nameValuePairs.add(new BasicNameValuePair("location",gps.toString()));
{"location":{"lat": "50.4", "lng": "30.5"}}
我需要发送浮点类型而不是字符串