private static URIRef relativeResolution ( URI target , URI base ) { URIRef Base = URIRef . create ( base ) ; // NOSONAR URIRef R = URIRef . create ( target ) ; // NOSONAR URIRef T = URIRef . create ( ) ; // NOSONAR if ( defined ( R . scheme ) ) { T . scheme = R . scheme ; T . authority = R . authority ; T . path = removeDotSegments ( R . path ) ; T . query = R . query ; } else { if ( defined ( R . authority ) ) { T . authority = R . authority ; T . path = removeDotSegments ( R . path ) ; T . query = R . query ; } else { resolvePathOnlyTarget ( Base , R , T ) ; } T . scheme = Base . scheme ; } T . fragment = R . fragment ; return T ; }
5 . 2 . Relative Resolution