Source:
<code>private static void saveWaypointsWithoutTransaction(final Geocache cache) { final String geocode = cache.getGeocode(); final List<Waypoint> waypoints = cache.getWaypoints(); if (CollectionUtils.isNotEmpty(waypoints)) { final List<String> currentWaypointIds = new ArrayList<>(); final ContentValues values = new ContentValues(); final long timeStamp = System.currentTimeMillis(); for (final Waypoint oneWaypoint : waypoints) { values.clear(); values.put("geocode", geocode); values.put("updated", timeStamp); values.put("type", oneWaypoint.getWaypointType() != null ? oneWaypoint.getWaypointType().id : null); values.put("prefix", oneWaypoint.getPrefix()); values.put("lookup", oneWaypoint.getLookup()); values.put("name", oneWaypoint.getName()); putCoords(values, oneWaypoint.getCoords()); values.put("note", oneWaypoint.getNote()); values.put("own", oneWaypoint.isUserDefined() ? 1 : 0); values.put("visited", oneWaypoint.isVisited() ? 1 : 0); values.put("user_note", oneWaypoint.getUserNote()); values.put("org_coords_empty", oneWaypoint.isOriginalCoordsEmpty() ? 1 : 0); try <START> { <END> values.put("calc_state", oneWaypoint.getCalculatorStoredState().toJSON().toString()); } catch (JSONException e) { values.put("calc_state", ""); } if (oneWaypoint.getId() < 0) { final long rowId = database.insert(dbTableWaypoints, null, values); oneWaypoint.setId((int) rowId); } else { database.update(dbTableWaypoints, values, "_id = ?", new String[] { Integer.toString(oneWaypoint.getId(), 10) }); } currentWaypointIds.add(Integer.toString(oneWaypoint.getId())); } removeOutdatedWaypointsOfCache(cache, currentWaypointIds); } }</code><technical_language>Brackets put line try catch: java try { } catch (final JSONException e) { }</technical_language>

Target:
private static void saveWaypointsWithoutTransaction(final Geocache cache) { final String geocode = cache.getGeocode(); final List<Waypoint> waypoints = cache.getWaypoints(); if (CollectionUtils.isNotEmpty(waypoints)) { final List<String> currentWaypointIds = new ArrayList<>(); final ContentValues values = new ContentValues(); final long timeStamp = System.currentTimeMillis(); for (final Waypoint oneWaypoint : waypoints) { values.clear(); values.put("geocode", geocode); values.put("updated", timeStamp); values.put("type", oneWaypoint.getWaypointType() != null ? oneWaypoint.getWaypointType().id : null); values.put("prefix", oneWaypoint.getPrefix()); values.put("lookup", oneWaypoint.getLookup()); values.put("name", oneWaypoint.getName()); putCoords(values, oneWaypoint.getCoords()); values.put("note", oneWaypoint.getNote()); values.put("own", oneWaypoint.isUserDefined() ? 1 : 0); values.put("visited", oneWaypoint.isVisited() ? 1 : 0); values.put("user_note", oneWaypoint.getUserNote()); values.put("org_coords_empty", oneWaypoint.isOriginalCoordsEmpty() ? 1 : 0); try { values.put("calc_state", oneWaypoint.getCalculatorStoredState().toJSON().toString()); } catch (final JSONException e) { values.put("calc_state", ""); } if (oneWaypoint.getId() < 0) { final long rowId = database.insert(dbTableWaypoints, null, values); oneWaypoint.setId((int) rowId); } else { database.update(dbTableWaypoints, values, "_id = ?", new String[] { Integer.toString(oneWaypoint.getId(), 10) }); } currentWaypointIds.add(Integer.toString(oneWaypoint.getId())); } removeOutdatedWaypointsOfCache(cache, currentWaypointIds); } }