Changeset 30262 in osm for applications/editors/josm/plugins/geochat/src/geochat/ChatServerConnection.java
- Timestamp:
- 2014-02-05T21:39:01+01:00 (11 years ago)
- Location:
- applications/editors/josm/plugins/geochat
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/geochat
- Property svn:ignore
-
old new 1 1 bin 2 build
-
- Property svn:ignore
-
applications/editors/josm/plugins/geochat/src/geochat/ChatServerConnection.java
r30234 r30262 402 402 try { 403 403 JsonObject msg = messages.getJsonObject(i); 404 long id = msg.getJsonNumber("id").longValue();405 double lat = msg.getJsonNumber("lat").doubleValue();406 double lon = msg.getJsonNumber("lon").doubleValue();407 long timeStamp = msg.getJsonNumber("timestamp").longValue();404 long id = Long.parseLong(msg.getString("id")); 405 double lat = Double.parseDouble(msg.getString("lat")); 406 double lon = Double.parseDouble(msg.getString("lon")); 407 long timeStamp = Long.parseLong(msg.getString("timestamp")); 408 408 String author = msg.getString("author"); 409 409 String message = msg.getString("message"); … … 428 428 JsonObject user = users.getJsonObject(i); 429 429 String name = user.getString("user"); 430 double lat = user.getJsonNumber("lat").doubleValue();431 double lon = user.getJsonNumber("lon").doubleValue();430 double lat = Double.parseDouble(user.getString("lat")); 431 double lon = Double.parseDouble(user.getString("lon")); 432 432 result.put(name, new LatLon(lat, lon)); 433 433 } catch( JsonException e ) {
Note:
See TracChangeset
for help on using the changeset viewer.