Supported file systems
Support for a file system is represented by a FileRepository.
FileManagerModule comes with 2 types of file repositories:
-
storage repositories that actual map file resources to an underlying storage provider like the local file system
-
special purpose repositories that enhance others with additional behaviors like caching, expiration…
Supported storage providers
The following storage provider implementations are available:
LocalFileRepository-
Stores all files as
Fileinstances in a root folder in the local filesystem. AmazonS3FileRepository-
Stores all files as AmazonS3 objects in a particular S3 bucket.
AzureFileRepository-
Stores all files as Blobs in a particular Azure Blob Storage container.
Special purpose file repositories
Additionally to the storage providers, the following special purpose repositories are also available:
ExpiringFileRepository-
Wraps around another
FileRepositoryand adds expiration mechanics to the file resources returned. Mostly useful for temporary files that you want to be automatically removed by the application after a given time. CachingFileRepository-
Wraps around a specific
FileRepositoryand creates a temporary cache version of every file resource, which it stores in another repository. Especially useful for file resources coming from a slow - usually remote -FileRepositorythat you want to cache locally for a given time.
Unlike theExpiringFileRepositorywhich expires the original file resource, theCachingFileRepositoryonly expires the cached version.
Adding a file system
Adding support for another file system is done by implementing your own FileRepository and FileResource.
See the separate section for more information.