java.lang.Object
de.digitalcollections.cudami.server.controller.identifiable.entity.parts.SubtopicController

@RestController
@Api(description="The subtopic controller",
     name="Subtopic controller")
public class SubtopicController
extends java.lang.Object
  • Constructor Summary

    Constructors 
    Constructor Description
    SubtopicController()  
  • Method Summary

    Modifier and Type Method Description
    de.digitalcollections.model.api.identifiable.entity.parts.Subtopic addSubtopicToParentSubtopic​(java.util.UUID parentSubtopicUuid, java.util.UUID subtopicUuid)  
    de.digitalcollections.model.api.identifiable.entity.parts.Subtopic addSubtopicToParentTopic​(java.util.UUID parentTopicUuid, java.util.UUID subtopicUuid)  
    long count()  
    de.digitalcollections.model.api.paging.PageResponse<de.digitalcollections.model.api.identifiable.entity.parts.Subtopic> findAll​(int pageNumber, int pageSize, java.util.List<de.digitalcollections.model.api.paging.Order> sortBy)  
    org.springframework.http.ResponseEntity<de.digitalcollections.model.api.view.BreadcrumbNavigation> getBreadcrumb​(java.util.UUID uuid, java.util.Locale pLocale)  
    java.util.List<de.digitalcollections.model.api.identifiable.entity.Entity> getEntities​(java.util.UUID uuid)  
    java.util.List<de.digitalcollections.model.api.identifiable.resource.FileResource> getFileResources​(java.util.UUID uuid)  
    org.springframework.http.ResponseEntity<de.digitalcollections.model.api.identifiable.entity.parts.Subtopic> getSubtopic​(java.util.UUID uuid, java.util.Locale pLocale)  
    de.digitalcollections.model.api.identifiable.entity.Topic getTopic​(java.util.UUID uuid, java.util.Locale pLocale)  
    java.util.List<de.digitalcollections.model.api.identifiable.entity.Entity> saveEntities​(java.util.UUID uuid, java.util.List<de.digitalcollections.model.api.identifiable.entity.Entity> entities)  
    java.util.List<de.digitalcollections.model.api.identifiable.resource.FileResource> saveFileresources​(java.util.UUID uuid, java.util.List<de.digitalcollections.model.api.identifiable.resource.FileResource> fileResources)  
    de.digitalcollections.model.api.identifiable.entity.parts.Subtopic saveWithParentSubtopic​(java.util.UUID parentSubtopicUuid, de.digitalcollections.model.api.identifiable.entity.parts.Subtopic subtopic)  
    de.digitalcollections.model.api.identifiable.entity.parts.Subtopic saveWithParentTopic​(java.util.UUID parentTopicUuid, de.digitalcollections.model.api.identifiable.entity.parts.Subtopic subtopic, org.springframework.validation.BindingResult errors)  
    de.digitalcollections.model.api.identifiable.entity.parts.Subtopic update​(java.util.UUID uuid, de.digitalcollections.model.api.identifiable.entity.parts.Subtopic subtopic, 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

  • Method Details

    • addSubtopicToParentSubtopic

      @ApiMethod(description="Add an existing subtopic to an existing parent subtopic") @PostMapping(value={"/latest/subtopics/{parentSubtopicUuid}/subtopic/{subtopicUuid}","/v2/subtopics/{parentSubtopicUuid}/subtopic/{subtopicUuid}"}, produces="application/json") @ApiResponseObject public de.digitalcollections.model.api.identifiable.entity.parts.Subtopic addSubtopicToParentSubtopic​(@ApiPathParam(name="parentSubtopicUuid",description="The uuid of the parent subtopic") @PathVariable java.util.UUID parentSubtopicUuid, @ApiPathParam(name="subtopicUuid",description="The uuid of the subtopic") @PathVariable java.util.UUID subtopicUuid) throws IdentifiableServiceException
      Throws:
      IdentifiableServiceException
    • addSubtopicToParentTopic

      @ApiMethod(description="Add an existing subtopic to an existing topic") @PostMapping(value={"/latest/topics/{parentTopicUuid}/subtopic/{subtopicUuid}","/v2/topics/{parentTopicUuid}/subtopic/{subtopicUuid}"}, produces="application/json") @ApiResponseObject public de.digitalcollections.model.api.identifiable.entity.parts.Subtopic addSubtopicToParentTopic​(@ApiPathParam(name="parentTopicUuid",description="The uuid of the parent topic") @PathVariable java.util.UUID parentTopicUuid, @ApiPathParam(name="subtopicUuid",description="The uuid of the subtopic") @PathVariable java.util.UUID subtopicUuid) throws IdentifiableServiceException
      Throws:
      IdentifiableServiceException
    • count

      @ApiMethod(description="Get count of subtopics") @GetMapping(value={"/latest/subtopics/count","/v2/subtopics/count"}, produces="application/json") @ApiResponseObject public long count()
    • findAll

      @ApiMethod(description="Get all subtopics") @GetMapping(value={"/latest/subtopics","/v2/subtopics"}, produces="application/json") @ApiResponseObject public de.digitalcollections.model.api.paging.PageResponse<de.digitalcollections.model.api.identifiable.entity.parts.Subtopic> findAll​(@RequestParam(name="pageNumber",required=false,defaultValue="0") int pageNumber, @RequestParam(name="pageSize",required=false,defaultValue="25") int pageSize, @RequestParam(name="sortBy",required=false) java.util.List<de.digitalcollections.model.api.paging.Order> sortBy)
    • getBreadcrumb

      @ApiMethod(description="Get the breadcrumb for a subtopic") @GetMapping(value={"/latest/subtopics/{uuid}/breadcrumb","/v3/subtopics/{uuid}/breadcrumb"}, produces="application/json") @ApiResponseObject public org.springframework.http.ResponseEntity<de.digitalcollections.model.api.view.BreadcrumbNavigation> getBreadcrumb​(@ApiPathParam(description="UUID of the subtopic, e.g. <tt>6119d8e9-9c92-4091-8dcb-bc4053385406</tt>") @PathVariable("uuid") java.util.UUID uuid, @ApiQueryParam(name="pLocale",description="Desired locale, e.g. <tt>de_DE</tt>. If unset, contents in all languages will be returned") @RequestParam(name="pLocale",required=false) java.util.Locale pLocale)
    • getEntities

      @ApiMethod(description="Get entities of subtopic") @GetMapping(value={"/latest/subtopics/{uuid}/entities","/v2/subtopics/{uuid}/entities"}, produces="application/json") @ApiResponseObject public java.util.List<de.digitalcollections.model.api.identifiable.entity.Entity> getEntities​(@ApiPathParam(name="uuid",description="The uuid of the subtopic") @PathVariable java.util.UUID uuid)
    • getFileResources

      @ApiMethod(description="Get file resources of subtopic") @GetMapping(value={"/latest/subtopics/{uuid}/fileresources","/v2/subtopics/{uuid}/fileresources"}, produces="application/json") @ApiResponseObject public java.util.List<de.digitalcollections.model.api.identifiable.resource.FileResource> getFileResources​(@PathVariable java.util.UUID uuid)
    • getSubtopic

      @ApiMethod(description="Get a subtopic as JSON or XML, depending on extension or <tt>format</tt> request parameter or accept header") @GetMapping(value={"/latest/subtopics/{uuid}","/v2/subtopics/{uuid}"}, produces={"application/json","application/xml"}) @ApiResponseObject public org.springframework.http.ResponseEntity<de.digitalcollections.model.api.identifiable.entity.parts.Subtopic> getSubtopic​(@ApiPathParam(description="UUID of the subtopic, e.g. <tt>599a120c-2dd5-11e8-b467-0ed5f89f718b</tt>") @PathVariable("uuid") java.util.UUID uuid, @ApiQueryParam(name="pLocale",description="Desired locale, e.g. <tt>de_DE</tt>. If unset, contents in all languages will be returned") @RequestParam(name="pLocale",required=false) java.util.Locale pLocale) throws IdentifiableServiceException
      Throws:
      IdentifiableServiceException
    • getTopic

      @ApiMethod(description="Get the topic of a subtopic") @GetMapping(value={"/latest/subtopics/{uuid}/topic","/v3/subtopics/{uuid}/topic"}, produces="application/json") @ApiResponseObject public de.digitalcollections.model.api.identifiable.entity.Topic getTopic​(@ApiPathParam(description="UUID of the subtopic, e.g. <tt>6119d8e9-9c92-4091-8dcb-bc4053385406</tt>") @PathVariable("uuid") java.util.UUID uuid, @ApiQueryParam(name="pLocale",description="Desired locale, e.g. <tt>de_DE</tt>. If unset, contents in all languages will be returned") @RequestParam(name="pLocale",required=false) java.util.Locale pLocale)
    • saveEntities

      @ApiMethod(description="Save entities of subtopic") @PostMapping(value={"/latest/subtopics/{uuid}/entities","/v2/subtopics/{uuid}/entities"}, produces="application/json") @ApiResponseObject public java.util.List<de.digitalcollections.model.api.identifiable.entity.Entity> saveEntities​(@PathVariable java.util.UUID uuid, @RequestBody java.util.List<de.digitalcollections.model.api.identifiable.entity.Entity> entities)
    • saveFileresources

      @ApiMethod(description="Save fileresources of subtopic") @PostMapping(value={"/latest/subtopics/{uuid}/fileresources","/v2/subtopics/{uuid}/fileresources"}, produces="application/json") @ApiResponseObject public java.util.List<de.digitalcollections.model.api.identifiable.resource.FileResource> saveFileresources​(@PathVariable java.util.UUID uuid, @RequestBody java.util.List<de.digitalcollections.model.api.identifiable.resource.FileResource> fileResources)
    • saveWithParentSubtopic

      @ApiMethod(description="Save a newly created subtopic") @PostMapping(value={"/latest/subtopics/{parentSubtopicUuid}/subtopic","/v2/subtopics/{parentSubtopicUuid}/subtopic"}, produces="application/json") @ApiResponseObject public de.digitalcollections.model.api.identifiable.entity.parts.Subtopic saveWithParentSubtopic​(@ApiPathParam(name="parentSubtopicUuid",description="The uuid of the parent subtopic") @PathVariable java.util.UUID parentSubtopicUuid, @RequestBody de.digitalcollections.model.api.identifiable.entity.parts.Subtopic subtopic) throws IdentifiableServiceException
      Throws:
      IdentifiableServiceException
    • saveWithParentTopic

      @ApiMethod(description="Save a newly created top-level subtopic") @PostMapping(value={"/latest/topics/{parentTopicUuid}/subtopic","/v2/topics/{parentTopicUuid}/subtopic"}, produces="application/json") @ApiResponseObject public de.digitalcollections.model.api.identifiable.entity.parts.Subtopic saveWithParentTopic​(@ApiPathParam(name="parentTopicUuid",description="The uuid of the parent topic") @PathVariable java.util.UUID parentTopicUuid, @RequestBody de.digitalcollections.model.api.identifiable.entity.parts.Subtopic subtopic, org.springframework.validation.BindingResult errors) throws IdentifiableServiceException
      Throws:
      IdentifiableServiceException
    • update

      @ApiMethod(description="Update a subtopic") @PutMapping(value={"/latest/subtopics/{uuid}","/v2/subtopics/{uuid}"}, produces="application/json") @ApiResponseObject public de.digitalcollections.model.api.identifiable.entity.parts.Subtopic update​(@ApiPathParam(name="uuid",description="The uuid of the subtopic") @PathVariable java.util.UUID uuid, @RequestBody de.digitalcollections.model.api.identifiable.entity.parts.Subtopic subtopic, org.springframework.validation.BindingResult errors) throws IdentifiableServiceException
      Throws:
      IdentifiableServiceException