A file storage management package supporting various providers like S3, OSS, and Qiniu.
Project description
efcFIle
通用的文件储存类
from efcFile import FileStorageManager, LocalFileStorage
manager = FileStorageManager(default_storage="local")
manager.set_storage("local", LocalFileStorage(storage_path="./storage/"))
manager.put("example.txt", b"This is a test file")
print(manager.get("example.txt"))
print(manager.exists("example.txt"))
print(manager.size("example.txt"))
print(manager.mime_type("example.txt"))
print(manager.list(""))
manager.move("example.txt", "example_moved.txt")
print(manager.exists("example_moved.txt"))
manager.delete("example_moved.txt")
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
efcfile-1.0.1.tar.gz
(5.3 kB
view details)
Built Distribution
File details
Details for the file efcfile-1.0.1.tar.gz
.
File metadata
- Download URL: efcfile-1.0.1.tar.gz
- Upload date:
- Size: 5.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.9.19
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a161e9b1a12d2489bbe050939a21f1a28e756009705153a7dcebc6e1ad618193 |
|
MD5 | a273fba04263746a98a26c66e7fe854b |
|
BLAKE2b-256 | 2632ef470b05a7469e7207468434f5d3b87681884c3c932609f6a37833e59e3b |
File details
Details for the file efcFile-1.0.1-py3-none-any.whl
.
File metadata
- Download URL: efcFile-1.0.1-py3-none-any.whl
- Upload date:
- Size: 7.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.9.19
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9110454e7730c459b42c1865bc37dbec4d6c80dbec05fab3df8825accd165c10 |
|
MD5 | d969adf90d4af3ea420f450ed19e7f74 |
|
BLAKE2b-256 | f862bf1e0746dad3cb74f417a5082fc6fe0679157d8f51e6297213c7ea3e6d7e |