public final String buildRelativeUrl ( ) { StringBuilder buf = new StringBuilder ( ) ; if ( pathParts != null ) { appendRawPathFromParts ( buf ) ; } addQueryParams ( entrySet ( ) , buf ) ; // URL fragment String fragment = this . fragment ; if ( fragment != null ) { buf . append ( ' ' ) . append ( URI_FRAGMENT_ESCAPER . escape ( fragment ) ) ; } return buf . toString ( ) ; }
Constructs the portion of the URL beginning at the rooted path .