src/org/kocakosm/pitaya/net/URLs.java
public static URL resolve(URL base, String path)
	{
		try {
			return base.toURI().resolve(path).normalize().toURL();
		} catch (URISyntaxException ex) {
			throw new IllegalArgumentException(ex);
		} catch (MalformedURLException ex) {
			throw new IllegalArgumentException(ex);
		}
	}
public static URL resolve(URL base, String path)
	{
		try {
			return base.toURI().resolve(path).normalize().toURL();
		} catch (URISyntaxException ex) {
			throw new IllegalArgumentException(ex);
		} catch (MalformedURLException ex) {
			throw new IllegalArgumentException(ex);
		}
	}
Resolves the specified path against the given base {@code URL}.
Behaves as {@link java.net.URI#resolve(java.lang.String)}.

@param base the base {@code URL}.
@param path the path to resolve.

@return the resolved {@code URL}.

@throws NullPointerException if one of the arguments is {@code null}.
@throws IllegalArgumentException if the path can't be resolved.