Class InstrumentController
- java.lang.Object
-
- no.nsd.qddt.domain.instrument.web.InstrumentController
-
@RestController @RequestMapping("/instrument") public class InstrumentController extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description InstrumentController(InstrumentService service)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Instrument
create(Instrument instrument)
void
delete(java.util.UUID id)
Instrument
get(java.util.UUID id)
org.springframework.http.HttpEntity<org.springframework.hateoas.PagedResources<InstrumentViewJson>>
getAll(org.springframework.data.domain.Pageable pageable, org.springframework.data.web.PagedResourcesAssembler assembler)
org.springframework.http.HttpEntity<org.springframework.hateoas.PagedResources<InstrumentViewJson>>
getBy(java.lang.String name, java.lang.String decsription, java.lang.String strKind, org.springframework.data.domain.Pageable pageable, org.springframework.data.web.PagedResourcesAssembler assembler)
byte[]
getPdf(java.util.UUID id)
java.lang.String
getXml(java.util.UUID id)
Instrument
update(Instrument instrument)
-
-
-
Constructor Detail
-
InstrumentController
@Autowired public InstrumentController(InstrumentService service)
-
-
Method Detail
-
get
@ResponseStatus(OK) @RequestMapping(value="{id}", method=GET) public Instrument get(@PathVariable("id") java.util.UUID id)
-
update
@ResponseStatus(OK) @RequestMapping(value="", method=POST) public Instrument update(@RequestBody Instrument instrument)
-
create
@ResponseStatus(CREATED) @RequestMapping(value="/create", method=POST) public Instrument create(@RequestBody Instrument instrument)
-
delete
@ResponseStatus(OK) @RequestMapping(value="/delete/{id}", method=DELETE) public void delete(@PathVariable("id") java.util.UUID id)
-
getAll
@RequestMapping(value="/page", method=GET, produces="application/json") public org.springframework.http.HttpEntity<org.springframework.hateoas.PagedResources<InstrumentViewJson>> getAll(org.springframework.data.domain.Pageable pageable, org.springframework.data.web.PagedResourcesAssembler assembler)
-
getBy
@RequestMapping(value="/page/search", method=GET, produces="application/json") public org.springframework.http.HttpEntity<org.springframework.hateoas.PagedResources<InstrumentViewJson>> getBy(@RequestParam(value="name",defaultValue="") java.lang.String name, @RequestParam(value="description",defaultValue="") java.lang.String decsription, @RequestParam(value="kind",defaultValue="") java.lang.String strKind, org.springframework.data.domain.Pageable pageable, org.springframework.data.web.PagedResourcesAssembler assembler)
-
getPdf
@ResponseBody @RequestMapping(value="/pdf/{id}", method=GET, produces="application/pdf") public byte[] getPdf(@PathVariable("id") java.util.UUID id)
-
getXml
@ResponseStatus(OK) @RequestMapping(value="/xml/{id}", method=GET) public java.lang.String getXml(@PathVariable("id") java.util.UUID id)
-
-