Package io.dialob.form.service.rest
Interface FormsRestService
-
- All Known Implementing Classes:
FormsRestServiceController
@RequestMapping("${dialob.api.context-path:}/forms") public interface FormsRestService
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description org.springframework.http.ResponseEntity<io.dialob.api.rest.Response>deleteForm(String formId)org.springframework.http.ResponseEntity<io.dialob.api.form.Form>getForm(String formId, String rev)org.springframework.http.ResponseEntity<List<FormListItem>>getForms(String metadata)org.springframework.http.ResponseEntity<io.dialob.api.form.FormTag>getFormTag(String formId, String tagName)org.springframework.http.ResponseEntity<List<io.dialob.api.form.FormTag>>getFormTags(String formId)org.springframework.http.ResponseEntity<io.dialob.api.form.FormPutResponse>itemCopy(String itemId, io.dialob.api.form.Form form)org.springframework.http.ResponseEntity<io.dialob.api.form.Form>postForm(io.dialob.api.form.Form formDocument)org.springframework.http.ResponseEntity<io.dialob.api.rest.Response>postFormTag(String formId, String rev, boolean snapshot, io.dialob.api.form.FormTag tag)org.springframework.http.ResponseEntity<io.dialob.api.form.FormPutResponse>putForm(String formId, String oldId, String newId, boolean forced, boolean dryRun, @NotNull io.dialob.api.form.Form formDocument)org.springframework.http.ResponseEntity<io.dialob.api.rest.Response>putFormTag(String formId, String tagName, io.dialob.api.form.FormTag updateTag)Update tag.org.springframework.http.ResponseEntity<io.dialob.api.rest.Response>putFormTagLatest(String formId, io.dialob.api.form.FormTag tag)
-
-
-
Method Detail
-
getForms
@GetMapping(produces="application/json") org.springframework.http.ResponseEntity<List<FormListItem>> getForms(@RequestParam(name="metadata",required=false) String metadata)
-
itemCopy
@PostMapping(path="/actions/itemCopy", produces="application/json", consumes="application/json") org.springframework.http.ResponseEntity<io.dialob.api.form.FormPutResponse> itemCopy(@RequestParam(name="itemId") String itemId, @Validated @RequestBody io.dialob.api.form.Form form)
-
postForm
@PostMapping(produces="application/json", consumes="application/json") org.springframework.http.ResponseEntity<io.dialob.api.form.Form> postForm(@RequestBody io.dialob.api.form.Form formDocument)
-
putForm
@PutMapping(path="{formId}", produces="application/json", consumes="application/json") org.springframework.http.ResponseEntity<io.dialob.api.form.FormPutResponse> putForm(@PathVariable("formId") String formId, @RequestParam(name="oldId",required=false) String oldId, @RequestParam(name="newId",required=false) String newId, @RequestParam(name="force",required=false,defaultValue="false") boolean forced, @RequestParam(name="dryRun",required=false,defaultValue="false") boolean dryRun, @Validated @NotNull @RequestBody @NotNull io.dialob.api.form.Form formDocument)- Parameters:
formId- logical form name or document idoldId-newId-formDocument-- Returns:
-
deleteForm
@DeleteMapping(path="{formId}") org.springframework.http.ResponseEntity<io.dialob.api.rest.Response> deleteForm(@PathVariable("formId") String formId)- Parameters:
formId- logical form name or document id- Returns:
-
getForm
@GetMapping(path="{formId}", produces="application/json") org.springframework.http.ResponseEntity<io.dialob.api.form.Form> getForm(@PathVariable("formId") String formId, @RequestParam(name="rev",required=false) String rev)- Parameters:
formId- document id or logical form namerev- name of tag- Returns:
-
getFormTags
@GetMapping(path="{formId}/tags", produces="application/json") org.springframework.http.ResponseEntity<List<io.dialob.api.form.FormTag>> getFormTags(@PathVariable("formId") String formId)- Parameters:
formId- logical form name or document id- Returns:
- list of tags
-
getFormTag
@GetMapping(path="{formId}/tags/{tagName}", produces="application/json") org.springframework.http.ResponseEntity<io.dialob.api.form.FormTag> getFormTag(@PathVariable("formId") String formId, @PathVariable("tagName") String tagName)- Parameters:
formId- logical form nametagName-- Returns:
-
postFormTag
@PostMapping(path="{formId}/tags", produces="application/json") org.springframework.http.ResponseEntity<io.dialob.api.rest.Response> postFormTag(@PathVariable("formId") String formId, @RequestParam(name="rev",required=false) String rev, @RequestParam(name="snapshot",required=false,defaultValue="false") boolean snapshot, @RequestBody io.dialob.api.form.FormTag tag)- Parameters:
formId- logical form namerev-tag-- Returns:
-
putFormTagLatest
@PutMapping(path="{formId}/tags/latest", produces="application/json") org.springframework.http.ResponseEntity<io.dialob.api.rest.Response> putFormTagLatest(@PathVariable("formId") String formId, @RequestBody io.dialob.api.form.FormTag tag)- Parameters:
formId- logical form nametag-- Returns:
-
putFormTag
@PutMapping(path="{formId}/tags/{tagName}", produces="application/json") org.springframework.http.ResponseEntity<io.dialob.api.rest.Response> putFormTag(@PathVariable("formId") String formId, @PathVariable("tagName") String tagName, @RequestBody io.dialob.api.form.FormTag updateTag)Update tag. Only mutable tag can be modified. Mutable tags can be set to existing tags only.- Parameters:
formId- logical form nameupdateTag-- Returns:
- updated tag
-
-