@NonNull
    private static Waypoint createWaypointFromDatabaseContent(final Cursor cursor) {
        final String name;
        final WaypointType type;
        final boolean own;
        try {
            name = cursor.getString(cursor.getColumnIndexOrThrow("name"));
            type = WaypointType.findById(cursor.getString(cursor.getColumnIndexOrThrow("type")));
            own = cursor.getInt(cursor.getColumnIndexOrThrow("own")) != 0;
        } catch (final IllegalArgumentException e) {
            Log.e("IllegalArgumentException in createWaypointFromDatabaseContent", e);
            throw new IllegalStateException("column not found in database");
        }
        final Waypoint waypoint = new Waypoint(name, type, own);
        try {
            waypoint.setVisited(cursor.getInt(cursor.getColumnIndexOrThrow("visited")) != 0);
            waypoint.setId(cursor.getInt(cursor.getColumnIndexOrThrow("_id")));
            waypoint.setGeocode(cursor.getString(cursor.getColumnIndexOrThrow("geocode")));
            waypoint.setPrefix(cursor.getString(cursor.getColumnIndexOrThrow("prefix")));
            waypoint.setLookup(cursor.getString(cursor.getColumnIndexOrThrow("lookup")));
            final Geopoint coords = getCoords(cursor, cursor.getColumnIndexOrThrow("latitude"), cursor.getColumnIndexOrThrow("longitude"));
            final Geopoint preprojectedCoords = getCoords(cursor, cursor.getColumnIndexOrThrow("preprojected_latitude"), cursor.getColumnIndexOrThrow("preprojected_longitude"));
            waypoint.setCoordsPure(coords);
            waypoint.setPreprojectedCoords(preprojectedCoords == null ? coords : preprojectedCoords); // older entries don't have preprojected coords stored
            waypoint.setNote(cursor.getString(cursor.getColumnIndexOrThrow("note")));
            waypoint.setUserNote(cursor.getString(cursor.getColumnIndexOrThrow("user_note")));
            waypoint.setOriginalCoordsEmpty(cursor.getInt(cursor.getColumnIndexOrThrow("org_coords_empty")) != 0);
            waypoint.setCalcStateConfig(cursor.getString(cursor.getColumnIndexOrThrow("calc_state")));
            waypoint.setProjection(
                ProjectionType.findById(cursor.getString(cursor.getColumnIndexOrThrow("projection_type"))),
                DistanceUnit.findById(cursor.getString(cursor.getColumnIndexOrThrow("projection_unit"))),
                cursor.getString(cursor.getColumnIndexOrThrow("projection_formula_1")),
                cursor.getString(cursor.getColumnIndexOrThrow("projection_formula_2"))
            );
            waypoint.setGeofence(cursor.getFloat(cursor.getColumnIndexOrThrow("geofence")));
        } catch (final IllegalArgumentException e) {
            Log.e("IllegalArgumentException in createWaypointFromDatabaseContent", e);
        }

        return waypoint;
    }
creates a Cache from the cursor. Doesn't next.

@return Cache from DB
main/src/main/java/cgeo/geocaching/storage/DataStore.java