Skip to main content

Mobio Filetype Libs

Project description

Thư viện kiểm tra file type.

Cài đặt:

 $ pip3 install m-filetype

Link chữ ký: https://en.wikipedia.org/wiki/List_of_file_signatures

Sử dụng

from mobio.sdks.filetype.file import File
from mobio.sdks.filetype.common import ExtensionImage

File.check_filetype_by_file_extensions(
    file_binary=file, # Check filetype của định dạng file binary.Mặc định None
    file_path=file_path, # Check filetype của path file
    extensions=[ExtensionImage.PNG] # Danh sách extension cần check.
)

Lấy extensions support

  • Extension Image:
from mobio.sdks.filetype.common import ExtensionImage
ExtensionImage.LIST_EXTENSION_SUPPORTED
  • Extension Document:
from mobio.sdks.filetype.common import ExtensionDocument
ExtensionDocument.LIST_EXTENSION_SUPPORTED
  • Extension Audio:
from mobio.sdks.filetype.common import ExtensionAudio
ExtensionAudio.LIST_EXTENSION_SUPPORTED

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

m-filetypes-0.1.7.tar.gz (19.8 kB view details)

Uploaded Source

File details

Details for the file m-filetypes-0.1.7.tar.gz.

File metadata

  • Download URL: m-filetypes-0.1.7.tar.gz
  • Upload date:
  • Size: 19.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.17

File hashes

Hashes for m-filetypes-0.1.7.tar.gz
Algorithm Hash digest
SHA256 e06f360a81de69647485b44fc2f91e8dcf7ba011f9506fdcfe854b88cbb3c657
MD5 51910a2ae7b1395653c6952f98961da4
BLAKE2b-256 652d0e6880c274702e01449e5c9781d3c058649534acbee48ef4a5c92812dce7

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page