コード例 #1
0
 /**
  * Update the pah (encoded) of this MutableUri.
  *
  * @param rawPath new path element (encoded)
  * @throws URISyntaxException if the new equivalent URI is invalid
  */
 public void setRawPath(String rawPath) throws URISyntaxException {
   uri =
       create(
           uri.getScheme(),
           uri.getRawUserInfo(),
           uri.getHost(),
           uri.getPort(),
           rawPath,
           uri.getRawQuery(),
           uri.getRawFragment());
   setResourcePath(uri.getRawPath());
 }
コード例 #2
0
 /**
  * Update the path (not encoded) of this MutableUri.
  *
  * @param path new path element (not encoded)
  * @throws URISyntaxException if the new equivalent URI is invalid
  */
 public void setPath(final String path) throws URISyntaxException {
   this.uri =
       new URI(
           uri.getScheme(),
           uri.getUserInfo(),
           uri.getHost(),
           uri.getPort(),
           path,
           uri.getQuery(),
           uri.getFragment());
   setResourcePath(uri.getPath());
 }
コード例 #3
0
 /**
  * Builds a new MutableUri using the given URI.
  *
  * @param uri URI
  */
 public MutableUri(final URI uri) {
   this.uri = uri;
   setResourcePath(uri.getRawPath());
 }