Package sonia.scm.api.v2.resources
Interface HalAppender
- All Known Implementing Classes:
EdisonHalAppender
public interface HalAppender
The
HalAppender
can be used within an HalEnricher
to append hateoas links to a json response.- Since:
- 2.0.0
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic interface
Builder for link arrays. -
Method Summary
Modifier and TypeMethodDescriptionvoid
appendEmbedded
(String rel, de.otto.edison.hal.HalRepresentation embeddedItem) Appends one embedded object to the json response.void
appendEmbedded
(String rel, List<de.otto.edison.hal.HalRepresentation> embeddedItems) Appends a list of embedded objects to the json response.void
appendLink
(String rel, String href) Appends one link to the json response.linkArrayBuilder
(String rel) Returns a builder which is able to append an array of links to the resource.
-
Method Details
-
appendLink
Appends one link to the json response.- Parameters:
rel
- name of relationhref
- link uri
-
linkArrayBuilder
Returns a builder which is able to append an array of links to the resource.- Parameters:
rel
- name of link relation- Returns:
- multi link builder
-
appendEmbedded
Appends one embedded object to the json response.- Parameters:
rel
- name of relationembeddedItem
- embedded object
-
appendEmbedded
Appends a list of embedded objects to the json response.- Parameters:
rel
- name of relationembeddedItems
- embedded objects
-