Class DMSFileRepository

    • Constructor Detail

      • DMSFileRepository

        public DMSFileRepository()
    • Method Detail

      • findHomeByRelated

        @Nullable
        public DMSFile findHomeByRelated​(Model related)
      • save

        public DMSFile save​(DMSFile entity)
        Description copied from interface: Repository
        Save the given entity.

        Depending on the implementation, it may return same entity or a copy of it. For example JPA implementation may return a copy if the given entity can't be managed.

        Specified by:
        save in interface Repository<DMSFile>
        Overrides:
        save in class JpaRepository<DMSFile>
        Parameters:
        entity - the entity object to save
        Returns:
        an instance of the entity with saved state
      • findOrCreateHome

        protected DMSFile findOrCreateHome​(Model related)
        Finds or creates parent folders.
        Parameters:
        related - model
        Returns:
        home parent
      • getRootParent

        @Nullable
        protected DMSFile getRootParent​(Model related)
        Gets root parent folder
        Parameters:
        related - model
        Returns:
        root parent folder
      • setOffline

        public DMSFile setOffline​(DMSFile file,
                                  boolean offline)
      • findOffline

        public List<DMSFile> findOffline​(int limit,
                                         int offset)