public RoutingTable routingMethod(RoutingMethod method) {
        Map<Endpoint, Target> copy = new TreeMap<>(table);
        copy.keySet().removeIf(endpoint -> !endpoint.routingMethod().equals(method));
        return new RoutingTable(copy, generation);
    }
Returns a copy of this containing only endpoints using given routing method
routing-generator/src/main/java/com/yahoo/vespa/hosted/routing/RoutingTable.java