private int getWaypointIndex(final Waypoint waypoint) {
        final int id = waypoint.getId();
        for (int index = 0; index < waypoints.size(); index++) {
            if (waypoints.get(index).getId() == id) {
                return index;
            }
        }
        return -1;
    }
Find index of given {@code waypoint} in cache's {@code waypoints} list

@param waypoint to find index for
@return index in {@code waypoints} if found, -1 otherwise
main/src/main/java/cgeo/geocaching/models/Geocache.java