Java Code Examples for org.apache.commons.httpclient.URI#getEscapedURI()
The following examples show how to use
org.apache.commons.httpclient.URI#getEscapedURI() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: JobEndNotifier.java From RDFS with Apache License 2.0 | 5 votes |
private static int httpNotification(String uri) throws IOException { URI url = new URI(uri, false); HttpClient m_client = new HttpClient(); HttpMethod method = new GetMethod(url.getEscapedURI()); method.setRequestHeader("Accept", "*/*"); return m_client.executeMethod(method); }
Example 2
Source File: JobEndNotifier.java From hadoop-gpu with Apache License 2.0 | 5 votes |
private static int httpNotification(String uri) throws IOException { URI url = new URI(uri, false); HttpClient m_client = new HttpClient(); HttpMethod method = new GetMethod(url.getEscapedURI()); method.setRequestHeader("Accept", "*/*"); return m_client.executeMethod(method); }
Example 3
Source File: DavExchangeSession.java From davmail with GNU General Public License v2.0 | 4 votes |
protected String getEscapedUrlFromPath(String escapedPath) throws URIException { URI uri = new URI(httpClient.getHostConfiguration().getHostURL(), true); uri.setEscapedPath(escapedPath); return uri.getEscapedURI(); }