public class BaseUri extends Object
Constructor and Description |
---|
BaseUri(String uri)
Creates a new
BaseUri with the given URI as base. |
BaseUri(URI uri)
Creates a new
BaseUri with the given URI as base. |
Modifier and Type | Method and Description |
---|---|
UriComponents |
appendPath(Path path)
|
String |
getRepositoryLookupPath(NativeWebRequest request)
Extracts the actual lookup path within the Spring Data REST managed URI space.
|
String |
getRepositoryLookupPath(String lookupPath)
Extracts the actual lookup path within the Spring Data REST managed URI space.
|
URI |
getUri()
Returns the base URI.
|
UriComponentsBuilder |
getUriComponentsBuilder()
Returns a new
UriComponentsBuilder for the base URI. |
public static final BaseUri NONE
public BaseUri(URI uri)
BaseUri
with the given URI as base.uri
- must not be null.public URI getUri()
public String getRepositoryLookupPath(NativeWebRequest request)
request
- must not be null.public String getRepositoryLookupPath(String lookupPath)
lookupPath
- must not be null.public UriComponentsBuilder getUriComponentsBuilder()
UriComponentsBuilder
for the base URI. If the base URI is not absolute, it'll lokup the URI
for the current servlet mapping and extend it accordingly.public UriComponents appendPath(Path path)
path
- must not be null.Copyright © 2011–2023 Pivotal Software, Inc.. All rights reserved.