Class TopicController
java.lang.Object
de.digitalcollections.cudami.server.controller.identifiable.entity.TopicController
@RestController
@Api(description="The topic controller",
name="Topic controller")
public class TopicController
extends java.lang.Object
-
Constructor Summary
Constructors Constructor Description TopicController() -
Method Summary
Modifier and Type Method Description longcount()de.digitalcollections.model.api.paging.PageResponse<de.digitalcollections.model.api.identifiable.entity.Topic>findAll(int pageNumber, int pageSize, java.lang.String sortField, de.digitalcollections.model.api.paging.enums.Direction sortDirection, de.digitalcollections.model.api.paging.enums.NullHandling nullHandling)de.digitalcollections.model.api.identifiable.entity.TopicfindById(java.util.UUID uuid)de.digitalcollections.model.api.identifiable.entity.Topicsave(de.digitalcollections.model.api.identifiable.entity.Topic topic, org.springframework.validation.BindingResult errors)de.digitalcollections.model.api.identifiable.entity.Topicupdate(java.util.UUID uuid, de.digitalcollections.model.api.identifiable.entity.Topic topic, org.springframework.validation.BindingResult errors)Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
TopicController
public TopicController()
-
-
Method Details
-
findAll
@ApiMethod(description="Get all topics") @GetMapping(value={"/latest/topics","/v2/topics"}, produces="application/json") @ApiResponseObject public de.digitalcollections.model.api.paging.PageResponse<de.digitalcollections.model.api.identifiable.entity.Topic> findAll(@RequestParam(name="pageNumber",required=false,defaultValue="0") int pageNumber, @RequestParam(name="pageSize",required=false,defaultValue="25") int pageSize, @RequestParam(name="sortField",required=false,defaultValue="lastModified") java.lang.String sortField, @RequestParam(name="sortDirection",required=false,defaultValue="DESC") de.digitalcollections.model.api.paging.enums.Direction sortDirection, @RequestParam(name="nullHandling",required=false,defaultValue="NATIVE") de.digitalcollections.model.api.paging.enums.NullHandling nullHandling) -
findById
@ApiMethod(description="Get topic by uuid") @GetMapping(value={"/latest/topics/{uuid}","/v2/topics/{uuid}"}, produces="application/json") @ApiResponseObject public de.digitalcollections.model.api.identifiable.entity.Topic findById(@PathVariable java.util.UUID uuid) -
save
@ApiMethod(description="Save a newly created topic") @PostMapping(value={"/latest/topics","/v2/topics"}, produces="application/json") @ApiResponseObject public de.digitalcollections.model.api.identifiable.entity.Topic save(@RequestBody de.digitalcollections.model.api.identifiable.entity.Topic topic, org.springframework.validation.BindingResult errors) throws IdentifiableServiceException- Throws:
IdentifiableServiceException
-
update
@ApiMethod(description="Update a topic") @PutMapping(value={"/latest/topics/{uuid}","/v2/topics/{uuid}"}, produces="application/json") @ApiResponseObject public de.digitalcollections.model.api.identifiable.entity.Topic update(@PathVariable java.util.UUID uuid, @RequestBody de.digitalcollections.model.api.identifiable.entity.Topic topic, org.springframework.validation.BindingResult errors) throws IdentifiableServiceException- Throws:
IdentifiableServiceException
-
count
@ApiMethod(description="Get count of topics") @GetMapping(value={"/latest/topics/count","/v2/topics/count"}, produces="application/json") @ApiResponseObject public long count()
-