org.apache.camel.component.http
Interface UrlRewrite

All Known Subinterfaces:
HttpServletUrlRewrite

public interface UrlRewrite

Allows to plugin custom strategy for rewriting url.

This allows for example to proxy http services and plugin a url rewrite strategy such as the url-rewrite component.


Method Summary
 String rewrite(String url, String relativeUrl, org.apache.camel.Producer producer)
          Rewrite the url.
 

Method Detail

rewrite

String rewrite(String url,
               String relativeUrl,
               org.apache.camel.Producer producer)
               throws Exception
Rewrite the url.

Parameters:
url - the absolute url (eg with scheme://host:port/path?query)
relativeUrl - optional relative url, if bridging endpoints, which then would be without the base path from the endpoint from the given producer.
producer - the producer to use the rewritten url
Returns:
the rewritten url, or null to use the original url
Throws:
Exception - is thrown if error rewriting the url


Apache Camel