public List<OsmNodeNamed> getWayPointList(final String lonLats) {
        if (lonLats == null) {
            throw new IllegalArgumentException("lonlats parameter not set");
        }

        final String[] coords = lonLats.split(";|\\|"); // use both variantes
        if (coords.length < 1 || !coords[0].contains(",")) {
            throw new IllegalArgumentException("we need one lat/lon point at least!");
        }

        final List<OsmNodeNamed> wplist = new ArrayList<>();
        for (int i = 0; i < coords.length; i++) {
            final String[] lonLat = coords[i].split(",");
            if (lonLat.length < 1) {
                throw new IllegalArgumentException("we need one lat/lon point at least!");
            }
            wplist.add(readPosition(lonLat[0], lonLat[1], "via" + i));
            if (lonLat.length > 2) {
                if (lonLat[2].equals("d")) {
                    wplist.get(wplist.size() - 1).direct = true;
                } else {
                    wplist.get(wplist.size() - 1).name = lonLat[2];
                }
            }
        }

        if (wplist.get(0).name.startsWith("via")) {
            wplist.get(0).name = "from";
        }
        if (wplist.get(wplist.size() - 1).name.startsWith("via")) {
            wplist.get(wplist.size() - 1).name = "to";
        }

        return wplist;
    }
get a list of points and optional extra info for the points

@param lonLats  linked list separated by ';' or '|'
@return         a list
main/src/main/java/cgeo/geocaching/brouter/core/RoutingParamCollector.java