Package org.dspace.app.rest.repository
Class VersionsLinkRepository
- java.lang.Object
-
- org.dspace.app.rest.repository.AbstractDSpaceRestRepository
-
- org.dspace.app.rest.repository.VersionsLinkRepository
-
- All Implemented Interfaces:
LinkRestRepository
@Component("versioning.versionhistory.versions") public class VersionsLinkRepository extends AbstractDSpaceRestRepository implements LinkRestRepositoryThis is the Repository that takes care of the retrieval of theVersionobjects for a givenVersionHistory
-
-
Field Summary
-
Fields inherited from class org.dspace.app.rest.repository.AbstractDSpaceRestRepository
converter, requestService, utils
-
-
Constructor Summary
Constructors Constructor Description VersionsLinkRepository()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.springframework.data.domain.Page<VersionRest>getVersions(javax.servlet.http.HttpServletRequest request, Integer versionHistoryId, org.springframework.data.domain.Pageable optionalPageable, Projection projection)This method will return a page of VersionRest objects found through the VersionHistory object that is resolved from the versionHistoryId parameter-
Methods inherited from class org.dspace.app.rest.repository.AbstractDSpaceRestRepository
getRequestService, obtainContext
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.dspace.app.rest.repository.LinkRestRepository
isEmbeddableRelation
-
-
-
-
Method Detail
-
getVersions
@PreAuthorize("@versioningSecurity.isEnableVersioning() && hasPermission(#versionHistoryId, \'VERSIONHISTORY\', \'READ\')") public org.springframework.data.domain.Page<VersionRest> getVersions(@Nullable javax.servlet.http.HttpServletRequest request, Integer versionHistoryId, @Nullable org.springframework.data.domain.Pageable optionalPageable, Projection projection) throws SQLExceptionThis method will return a page of VersionRest objects found through the VersionHistory object that is resolved from the versionHistoryId parameter- Parameters:
request- The current requestversionHistoryId- The ID for the VersionHistory to be usedoptionalPageable- The pageable if presentprojection- The current Projection- Returns:
- The page containing relevant VersionRest objects
- Throws:
SQLException- If something goes wrong
-
-