Package 

Class MultipartConfig

  • All Implemented Interfaces:

    
    public final class MultipartConfig
    
                        

    This class contains the configuration for handling multipart file uploads

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      final Unit cacheDirectory(String path) Sets the location of the cache directory used to write file uploads
      final Unit maxFileSize(Long size, SizeUnit sizeUnit) Sets the maximum file size for an individual file upload
      final Unit maxInMemoryFileSize(Integer size, SizeUnit sizeUnit) Sets the maximum size for a single file before it will be cached to disk rather than read in memory
      final Unit maxTotalRequestSize(Long size, SizeUnit sizeUnit) Sets the maximum size for the entire multipart request
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • MultipartConfig

        MultipartConfig()
    • Method Detail

      • cacheDirectory

         final Unit cacheDirectory(String path)

        Sets the location of the cache directory used to write file uploads

        Parameters:
        path - : the path of the cache directory used to write file uploads maxInMemoryFileSize
      • maxFileSize

         final Unit maxFileSize(Long size, SizeUnit sizeUnit)

        Sets the maximum file size for an individual file upload

        Parameters:
        size - : the maximum size of the file
        sizeUnit - : the units that this size is measured in
      • maxInMemoryFileSize

         final Unit maxInMemoryFileSize(Integer size, SizeUnit sizeUnit)

        Sets the maximum size for a single file before it will be cached to disk rather than read in memory

        Parameters:
        size - : the maximum size of the file
        sizeUnit - : the units that this size is measured in
      • maxTotalRequestSize

         final Unit maxTotalRequestSize(Long size, SizeUnit sizeUnit)

        Sets the maximum size for the entire multipart request

        Parameters:
        size - : the maximum size of the file
        sizeUnit - : the units that this size is measured in