Resolves a given relative URL against a base URL. See RFC1808 Section 4 for more details. @param baseUrl The base URL in which to resolve the specification. @param relativeUrl The relative URL to resolve against the base URL. @return the resol
(final String baseUrl, final String relativeUrl)
| 670 | * @return the resolved specification. |
| 671 | */ |
| 672 | public static String resolveUrl(final String baseUrl, final String relativeUrl) { |
| 673 | if (baseUrl == null) { |
| 674 | throw new IllegalArgumentException("Base URL must not be null"); |
| 675 | } |
| 676 | if (relativeUrl == null) { |
| 677 | throw new IllegalArgumentException("Relative URL must not be null"); |
| 678 | } |
| 679 | final Url url = resolveUrl(parseUrl(baseUrl), relativeUrl); |
| 680 | |
| 681 | return url.toString(); |
| 682 | } |
| 683 | |
| 684 | /** |
| 685 | * Resolves a given relative URL against a base URL. See |