Class AdaptiveFileUploadFactory

    • Field Detail

      • memoryThreshold

        protected int memoryThreshold
      • uploadPath

        protected java.io.File uploadPath
      • maxFileSize

        protected int maxFileSize
      • breakOnError

        protected boolean breakOnError
      • fileExtensions

        protected java.lang.String[] fileExtensions
      • allowFileExtensions

        protected boolean allowFileExtensions
    • Constructor Detail

      • AdaptiveFileUploadFactory

        public AdaptiveFileUploadFactory()
    • Method Detail

      • getMemoryThreshold

        public int getMemoryThreshold()
      • setMemoryThreshold

        public AdaptiveFileUploadFactory setMemoryThreshold​(int memoryThreshold)
        Specifies per file memory limit for keeping uploaded files in the memory.
      • getUploadPath

        public java.io.File getUploadPath()
      • setUploadPath

        public AdaptiveFileUploadFactory setUploadPath​(java.io.File uploadPath)
        Specifies the upload path. If set to null default system TEMP path will be used.
      • getMaxFileSize

        public int getMaxFileSize()
      • setMaxFileSize

        public AdaptiveFileUploadFactory setMaxFileSize​(int maxFileSize)
        Sets maximum file upload size. Setting to -1 disables this constraint.
      • isBreakOnError

        public boolean isBreakOnError()
      • breakOnError

        public AdaptiveFileUploadFactory breakOnError​(boolean breakOnError)
        Specifies if upload should break on error.
      • setFileExtensions

        public AdaptiveFileUploadFactory setFileExtensions​(java.lang.String[] fileExtensions,
                                                           boolean allow)
        Allow or disallow set of file extensions. Only one rule can be active at time, which means user can only specify extensions that are either allowed or disallowed. Setting this value to null will turn this feature off.