Class AbstractArchivedNodeWebScript

  • All Implemented Interfaces:
    org.springframework.extensions.webscripts.WebScript
    Direct Known Subclasses:
    ArchivedNodePut, ArchivedNodesDelete, ArchivedNodesGet

    public abstract class AbstractArchivedNodeWebScript
    extends org.springframework.extensions.webscripts.DeclarativeWebScript
    This class is an abstract base class for the various webscript controllers in the NodeArchiveService.
    Since:
    3.5
    Author:
    Neil McErlean, Jamal Kaabi-Mofrad
    • Constructor Detail

      • AbstractArchivedNodeWebScript

        public AbstractArchivedNodeWebScript()
    • Method Detail

      • setServiceRegistry

        public void setServiceRegistry​(ServiceRegistry serviceRegistry)
        Sets the serviceRegistry instance
        Parameters:
        serviceRegistry - the serviceRegistry to set
      • setNodeArchiveService

        public void setNodeArchiveService​(NodeArchiveService nodeArchiveService)
        Sets the nodeArchiveService instance
        Parameters:
        nodeArchiveService - the nodeArchiveService to set
      • setMaxSizeView

        public void setMaxSizeView​(int maxSizeView)
        Sets the maxSizeView
        Parameters:
        maxSizeView - the maxSizeView
      • parseRequestForStoreRef

        protected StoreRef parseRequestForStoreRef​(org.springframework.extensions.webscripts.WebScriptRequest req)
      • parseRequestForNodeRef

        protected NodeRef parseRequestForNodeRef​(org.springframework.extensions.webscripts.WebScriptRequest req)
      • getIntParameter

        protected int getIntParameter​(org.springframework.extensions.webscripts.WebScriptRequest req,
                                      String paramName,
                                      int defaultValue)
        Retrieves the named parameter as an integer, if the parameter is not present the default value is returned
        Parameters:
        req - The WebScript request
        paramName - The name of parameter to look for
        defaultValue - The default value that should be returned if parameter is not present in request or if it is not positive
        Returns:
        The request parameter or default value
      • getArchivedNodesFrom

        protected org.alfresco.query.PagingResults<NodeRef> getArchivedNodesFrom​(StoreRef storeRef,
                                                                                 ScriptPagingDetails paging,
                                                                                 String filter)
        * This method gets all nodes from the archive which were originally contained within the specified StoreRef.
        Parameters:
        storeRef - mandatory store ref
        paging - mandatory paging
        filter - optional filter
      • validatePermission

        protected void validatePermission​(NodeRef nodeRef,
                                          String currentUser)