Add a simple URLRewriter class to the HTTPClient

The new URLRewriter class allows you to provide custom URL rewriting
logic to modify urls right before they are sent to the server.