Rewrite the supplied URL.
The supplied URL may be marked as read only in which case this method must copy it before making any changes. If it is not so marked then this method may make it read only. If necessary the returned URL may also be marked as read only.
The normal reason for making a URL read only is because it is to be stored in a cache for reuse later in which case allowing it to be modified could invalidate the cache contents.
The supplied URL may be document relative, host relative, or absolute and it is the responsibility of this method to deal with each type appropriately. The returned URL may also be in any of those forms and again it is the responsibility of this method to ensure that relative URLs resolve to the appropriate absolute URL.
@param context The context of the current request.
@param url The url that needs rewriting, may not be null.
@param details Information about the use that will be made of the urlthat may affect how it is rewritten.
@return The url to add to the page, may not be null.