|
Spring Hateoas | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.springframework.hateoas.client.Traverson
public class Traverson
Component to ease traversing hypermedia APIs by following links with relation types. Highly inspired by the equally named JavaScript library.
https://github.com/basti1302/traverson| Nested Class Summary | |
|---|---|
class |
Traverson.TraversalBuilder
Builder API to customize traversals. |
| Constructor Summary | |
|---|---|
Traverson(URI baseUri,
MediaType... mediaTypes)
Creates a new Traverson interacting with the given base URI and using the given MediaTypes to
interact with the service. |
|
| Method Summary | |
|---|---|
Traverson.TraversalBuilder |
follow(String... rels)
Sets up a Traverson.TraversalBuilder to follow the given rels. |
Traverson |
setLinkDiscoverers(List<? extends LinkDiscoverer> discoverer)
Sets the LinkDiscoverers to use. |
Traverson |
setRestOperations(RestOperations operations)
Configures the RestOperations to use. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Traverson(URI baseUri,
MediaType... mediaTypes)
Traverson interacting with the given base URI and using the given MediaTypes to
interact with the service.
baseUri - must not be null.mediaType - must not be null or empty.| Method Detail |
|---|
public Traverson setRestOperations(RestOperations operations)
RestOperations to use. If null is provided a default RestTemplate will be
used.
operations -
public Traverson setLinkDiscoverers(List<? extends LinkDiscoverer> discoverer)
LinkDiscoverers to use. By default a single HalLinkDiscoverer is registered. If
null is provided the default is reapplied.
discoverer - can be null.
public Traverson.TraversalBuilder follow(String... rels)
Traverson.TraversalBuilder to follow the given rels.
rels - must not be null or empty.
Traverson.TraversalBuilder
|
Spring Hateoas | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||