private void setResponseLocation(URL url) {
        String location = url.getPath();
        String query = url.getQuery();
        if (query != null) {
            int startOfQuery = location.indexOf(query);
            if (startOfQuery > 0) {
                location = location.substring(0, startOfQuery);
            }
        }
        connection.getResHeader().add("Location", location);
    }
private void setResponseLocation ( URL url ) { String location = url . getPath ( ) ; String query = url . getQuery ( ) ; if ( query != null ) { int startOfQuery = location . indexOf ( query ) ; if ( startOfQuery > 0 ) { location = location . substring ( 0 , startOfQuery ) ; } } connection . getResHeader ( ) . add ( "Location" , location ) ; }
Router+Handlers