private Path convertPath(Path path) throws Exception {
  if (mode != PROXY)   return path;
 else {
    URI secondaryUri=new URI(SECONDARY_URI);
    URI pathUri=path.toUri();
    return new Path(new URI(pathUri.getScheme() != null ? secondaryUri.getScheme() : null,pathUri.getAuthority() != null ? secondaryUri.getAuthority() : null,pathUri.getPath(),null,null));
  }
}

private Path convertPath ( Path path ) throws Exception { if ( mode != PROXY ) return path ; else { URI secondaryUri = new URI ( SECONDARY_URI ) ; URI pathUri = path . toUri ( ) ; return new Path ( new URI ( pathUri . getScheme ( ) != null ? secondaryUri . getScheme ( ) : null , pathUri . getAuthority ( ) != null ? secondaryUri . getAuthority ( ) : null , pathUri . getPath ( ) , null , null ) ) ; } }
convert path for exception message testing purposes .
