parent
c19fc9d53f
commit
b1d84067cd
|
|
@ -186,7 +186,13 @@ public class UriComponentsBuilder implements UriBuilder, Cloneable {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Create a builder that is initialized with the given {@code URI}.
|
* Create a builder that is initialized from the given {@code URI}.
|
||||||
|
* <p><strong>Note:</strong> the components in the resulting builder will be
|
||||||
|
* in fully encoded (raw) form and further changes must also supply values
|
||||||
|
* that are fully encoded, for example via methods in {@link UriUtils}.
|
||||||
|
* In addition please use {@link #build(boolean)} with a value of "true" to
|
||||||
|
* build the {@link UriComponents} instance in order to indicate that the
|
||||||
|
* components are encoded.
|
||||||
* @param uri the URI to initialize with
|
* @param uri the URI to initialize with
|
||||||
* @return the new {@code UriComponentsBuilder}
|
* @return the new {@code UriComponentsBuilder}
|
||||||
*/
|
*/
|
||||||
|
|
@ -387,11 +393,13 @@ public class UriComponentsBuilder implements UriBuilder, Cloneable {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Build a {@code UriComponents} instance from the various components
|
* Variant of {@link #build()} to create a {@link UriComponents} instance
|
||||||
* contained in this builder.
|
* when components are already fully encoded. This is useful for example if
|
||||||
* @param encoded whether all the components set in this builder are
|
* the builder was created via {@link UriComponentsBuilder#fromUri(URI)}.
|
||||||
* encoded ({@code true}) or not ({@code false})
|
* @param encoded whether the components in this builder are already encoded
|
||||||
* @return the URI components
|
* @return the URI components
|
||||||
|
* @throws IllegalArgumentException if any of the components contain illegal
|
||||||
|
* characters that should have been encoded.
|
||||||
*/
|
*/
|
||||||
public UriComponents build(boolean encoded) {
|
public UriComponents build(boolean encoded) {
|
||||||
return buildInternal(encoded ?
|
return buildInternal(encoded ?
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue