Package de.trustable.ca3s.core.web.rest
Class PipelineViewResource
- java.lang.Object
-
- de.trustable.ca3s.core.web.rest.PipelineViewResource
-
-
Constructor Summary
Constructors Constructor Description PipelineViewResource(PipelineService pipelineService, PipelineUtil pipelineUtil)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.springframework.http.ResponseEntity<PipelineView>createPipeline(@Valid PipelineView pipelineView)POST /pipelineViews: Create a new pipeline.org.springframework.http.ResponseEntity<Void>deletePipeline(Long id)DELETE /pipelines/:id: delete the "id" pipeline.List<PipelineView>getAllPipelines()GET /pipelineViews: get all the pipelines.org.springframework.http.ResponseEntity<PipelineView>getPipeline(Long id)GET /pipelineViews/:id: get the "id" pipeline.org.springframework.http.ResponseEntity<PipelineView>updatePipeline(@Valid PipelineView pipelineView)PUT /pipelineViews: Updates an existing pipeline.
-
-
-
Constructor Detail
-
PipelineViewResource
public PipelineViewResource(PipelineService pipelineService, PipelineUtil pipelineUtil)
-
-
Method Detail
-
createPipeline
@PostMapping("/pipelineViews") @PreAuthorize("hasRole(\"ROLE_ADMIN\")") public org.springframework.http.ResponseEntity<PipelineView> createPipeline(@Valid @RequestBody @Valid PipelineView pipelineView) throws URISyntaxExceptionPOST /pipelineViews: Create a new pipeline.- Parameters:
pipelineView- the pipeline to create.- Returns:
- the
ResponseEntitywith status201 (Created)and with body the new pipeline, or with status400 (Bad Request)if the pipeline has already an ID. - Throws:
URISyntaxException- if the Location URI syntax is incorrect.
-
updatePipeline
@PutMapping("/pipelineViews") @PreAuthorize("hasRole(\"ROLE_ADMIN\")") public org.springframework.http.ResponseEntity<PipelineView> updatePipeline(@Valid @RequestBody @Valid PipelineView pipelineView) throws URISyntaxExceptionPUT /pipelineViews: Updates an existing pipeline.- Parameters:
pipelineView- the pipeline to update.- Returns:
- the
ResponseEntitywith status200 (OK)and with body the updated pipeline, or with status400 (Bad Request)if the pipeline is not valid, or with status500 (Internal Server Error)if the pipeline couldn't be updated. - Throws:
URISyntaxException- if the Location URI syntax is incorrect.
-
getAllPipelines
@GetMapping("/pipelineViews") public List<PipelineView> getAllPipelines()GET /pipelineViews: get all the pipelines.- Returns:
- the
ResponseEntitywith status200 (OK)and the list of pipelines in body.
-
getPipeline
@GetMapping("/pipelineViews/{id}") public org.springframework.http.ResponseEntity<PipelineView> getPipeline(@PathVariable Long id)GET /pipelineViews/:id: get the "id" pipeline.- Parameters:
id- the id of the pipeline to retrieve.- Returns:
- the
ResponseEntitywith status200 (OK)and with body the pipeline, or with status404 (Not Found).
-
deletePipeline
@DeleteMapping("/pipelineViews/{id}") @PreAuthorize("hasRole(\"ROLE_ADMIN\")") public org.springframework.http.ResponseEntity<Void> deletePipeline(@PathVariable Long id)DELETE /pipelines/:id: delete the "id" pipeline.- Parameters:
id- the id of the pipeline to delete.- Returns:
- the
ResponseEntitywith status204 (NO_CONTENT).
-
-