# Uses of Interface
org.springframework.web.util.UriBuilder

Packages that use UriBuilder
Package
Description
org.springframework.web.client
Core package of the client-side web support.
org.springframework.web.util
Miscellaneous web utility classes, such as HTML escaping and cookie handling.

## Uses of UriBuilder in org.springframework.web.client

Method parameters in org.springframework.web.client with type arguments of type UriBuilder
Modifier and Type
Method
Description
`S`
RestClient.UriSpec.`uri(String uri, Function<UriBuilder,URI> uriFunction)`
Specify the URI starting with a URI template and finishing off with a `UriBuilder` created from the template.
`S`
RestClient.UriSpec.`uri(Function<UriBuilder,URI> uriFunction)`
Specify the URI by through a `UriBuilder`.

## Uses of UriBuilder in org.springframework.web.util

Classes in org.springframework.web.util that implement UriBuilder
Modifier and Type
Class
Description
`class`
`UriComponentsBuilder`
Builder for `UriComponents`.
Methods in org.springframework.web.util that return UriBuilder
Modifier and Type
Method
Description
`UriBuilder`
DefaultUriBuilderFactory.`builder()`
`UriBuilder`
UriBuilderFactory.`builder()`
Create a URI builder with default settings.
`UriBuilder`
UriBuilder.`fragment(String fragment)`
Set the URI fragment.
`UriBuilder`
UriBuilder.`host(String host)`
Set the URI host which may contain URI template variables, and may also be `null` to clear the host of this builder.
`UriBuilder`
UriBuilder.`path(String path)`
Append to the path of this builder.
`UriBuilder`
UriBuilder.`pathSegment(String... pathSegments)`
Append to the path using path segments.
`UriBuilder`
UriBuilder.`port(int port)`
Set the URI port.
`UriBuilder`
UriBuilder.`port(String port)`
Set the URI port.
`UriBuilder`
UriBuilder.`query(String query)`
Parse the given query string into query parameters where parameters are separated with `'&'` and their values, if any, with `'='`.
`UriBuilder`
UriBuilder.`queryParam(String name, Object... values)`
Append the given query parameter.
`UriBuilder`
UriBuilder.`queryParam(String name, Collection<?> values)`
Variant of `queryParam(String, Object...)` with a Collection.
`UriBuilder`
UriBuilder.`queryParamIfPresent(String name, Optional<?> value)`
Delegates to either `queryParam(String, Object...)` or `queryParam(String, Collection)` if the given `Optional` has a value, or else if it is empty, no query parameter is added at all.
`UriBuilder`
UriBuilder.`queryParams(org.springframework.util.MultiValueMap<String,String> params)`
Add multiple query parameters and values.
`UriBuilder`
UriBuilder.`replacePath(String path)`
Override the current path.
`UriBuilder`
UriBuilder.`replaceQuery(String query)`
Clear existing query parameters and then delegate to `query(String)`.
`UriBuilder`
UriBuilder.`replaceQueryParam(String name, Object... values)`
Set the query parameter values replacing existing values, or if no values are given, the query parameter is removed.
`UriBuilder`
UriBuilder.`replaceQueryParam(String name, Collection<?> values)`
Variant of `replaceQueryParam(String, Object...)` with a Collection.
`UriBuilder`
UriBuilder.`replaceQueryParams(org.springframework.util.MultiValueMap<String,String> params)`
Set the query parameter values after removing all existing ones.
`UriBuilder`
UriBuilder.`scheme(String scheme)`
Set the URI scheme which may contain URI template variables, and may also be `null` to clear the scheme of this builder.
`UriBuilder`
DefaultUriBuilderFactory.`uriString(String uriTemplate)`
`UriBuilder`
UriBuilderFactory.`uriString(String uriTemplate)`
Initialize a builder with the given URI template.
`UriBuilder`
UriBuilder.`userInfo(String userInfo)`
Set the URI user info which may contain URI template variables, and may also be `null` to clear the user info of this builder.