title: What happened to URIUtil.encodePath from commons-httpclient-3.1?
body: <p>I want to do what's described in question <a href="https://stackoverflow.com/questions/724043/http-url-address-encoding-in-java">724043</a>, namely encode the path components of a URI. The class recommended to do that is <a href="http://hc.apache.org/httpclient-3.x/apidocs/org/apache/commons/httpclient/util/URIUtil.html" rel="nofollow noreferrer">URIUtil</a> from Commons HttpClient 3.1. Unfortunately, that class seems to have disappeared from the most recent version of HttpClient. A similarly named class from HttpClient 4.1, <a href="http://hc.apache.org/httpcomponents-client/httpclient/apidocs/org/apache/http/client/utils/URIUtils.html" rel="nofollow noreferrer">URIUtils</a>, doesn't provide the same functionality. Has this class/method been moved to some other library that I'm not aware of or is it just gone? Am I best off just copying the class from the 3.1 release into my code or is there a simpler way?</p>