The official doc says that PageReferences
could manage both partial an absolute without problem.
PageReference pageRef = new PageReference('partialURL');
Creates a PageReference to any page that is hosted on the Force.com
platform. For example, setting 'partialURL' to '/apex/HelloWorld'
refers to the Visualforce page located at
http://mySalesforceInstance/apex/HelloWorld
. Likewise, setting
'partialURL' to '/' + 'recordID' refers to the detail page for the
specified record.
This syntax is less preferable for referencing other Visualforce pages
than Page.existingPageName
because the PageReference
is constructed at
runtime, rather than referenced at compile time. Runtime references
are not available to the referential integrity system. Consequently,
the platform doesn't recognize that this controller or controller
extension is dependent on the existence of the specified page and
won't issue an error message to prevent user deletion of the page.
PageReference pageRef = new PageReference('fullURL');
Creates a PageReference for an external URL. For example:
PageReference pageRef = new PageReference('http://www.google.com');
Finally, no matter how Apex manage PageReference. The Url will be analyzed and the browser will request it properly.