@RestController @RequestMapping(value="anchor") public class AnchorResource extends ProtectedResource
Although not required, this class is instantiated using the Jersey SpringServlet and dependencies are defined in the Sprint context XML file.
| Constructor and Description |
|---|
AnchorResource()
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
reactor.core.publisher.Mono<Void> |
addAnchor(org.nhindirect.config.model.Anchor anchor)
Adds an anchor to the system.
|
reactor.core.publisher.Flux<org.nhindirect.config.model.Anchor> |
getAnchorForOwner(boolean incoming,
boolean outgoing,
String thumbprint,
String owner)
Gets a set of list of anchor for a given owner of the anchor.
|
reactor.core.publisher.Flux<org.nhindirect.config.model.Anchor> |
getAnchors()
Gets all anchors in the system.
|
reactor.core.publisher.Mono<Void> |
removeAnchorsByIds(String ids)
Deletes anchor from the system by system id.
|
reactor.core.publisher.Mono<Void> |
removeAnchorsByOwner(String owner)
Delete all anchors for a specific owner.
|
void |
setAnchorRepository(org.nhindirect.config.repository.AnchorRepository anchorRepo)
Sets the anchor repository.
|
@Autowired public void setAnchorRepository(org.nhindirect.config.repository.AnchorRepository anchorRepo)
anchorRepo - Anchor repository@GetMapping(value="/{owner}",
produces="application/json")
public reactor.core.publisher.Flux<org.nhindirect.config.model.Anchor> getAnchorForOwner(@RequestParam(name="incoming",defaultValue="false")
boolean incoming,
@RequestParam(name="outgoing",defaultValue="false")
boolean outgoing,
@RequestParam(name="thumbprint",defaultValue="")
String thumbprint,
@PathVariable(value="owner")
String owner)
incoming - Returned anchors must be marked for use of incoming messages. Defaults to false meaning that no filter is applied.outgoing - Returned anchors must be marked for use of outgoing messages. Defaults to false meaning that no filter is applied.thumbprint - Returned anchors that match a specific thumbprint effectively limiting the number of returned anchors to 1.
Defaults to an empty string meaning that no filter is applied.owner - The owner to retrieve anchors for.@GetMapping(produces="application/json") public reactor.core.publisher.Flux<org.nhindirect.config.model.Anchor> getAnchors()
@PutMapping(consumes="application/json") @ResponseStatus(value=CREATED) public reactor.core.publisher.Mono<Void> addAnchor(@RequestBody org.nhindirect.config.model.Anchor anchor)
uriInfo - Injected URI context used for building the location URI.anchor - The anchor to add to the system.@DeleteMapping(value="ids/{ids}")
public reactor.core.publisher.Mono<Void> removeAnchorsByIds(@PathVariable(value="ids")
String ids)
ids - List of ids to delete from the system.@DeleteMapping(value="{owner}")
public reactor.core.publisher.Mono<Void> removeAnchorsByOwner(@PathVariable(value="owner")
String owner)
owner - The owner to delete anchor from.Copyright © 2022. All rights reserved.