Media Type parsing and creation
Project description
mediatype
Media Type (aka MIME Type) parsing and creation
Installation
pip install mediatype
Usage
>>> import mediatype
Parsing
>>> media_type = mediatype.parse('application/manifest+json')
>>>
>>> media_type
MediaType(
type='application',
subtype='manifest',
suffix='json',
parameters=None
)
>>>
>>> str(media_type)
'application/manifest+json'
Creation
>>> media_type = mediatype.MediaType(
type='application',
subtype='manifest',
suffix='json',
parameters=None
)
>>>
>>> str(media_type)
'application/manifest+json'
References
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
mediatype-0.1.6.tar.gz
(27.2 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
mediatype-0.1.6-py3-none-any.whl
(27.3 kB
view details)
File details
Details for the file mediatype-0.1.6.tar.gz.
File metadata
- Download URL: mediatype-0.1.6.tar.gz
- Upload date:
- Size: 27.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.12 CPython/3.8.10 Linux/5.4.0-107-generic
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c8e6bd3b4eb7122d99b37982eeb72a482f086dcc13cdf7b8fd557c7009ecf7ae
|
|
| MD5 |
9fd7e492313a8d32831c8bd4df3dddbd
|
|
| BLAKE2b-256 |
1b6bd926170bae50fa933c170bb012d8eb24fe3c0f0c815647d63539d65819b0
|
File details
Details for the file mediatype-0.1.6-py3-none-any.whl.
File metadata
- Download URL: mediatype-0.1.6-py3-none-any.whl
- Upload date:
- Size: 27.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.12 CPython/3.8.10 Linux/5.4.0-107-generic
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ce468de263736801fe9a5ba2e7a9aa51e8cc8358c31841d91a5c9fa3ee12aa26
|
|
| MD5 |
cc28cee10099ce9a59f3fdcda51d7988
|
|
| BLAKE2b-256 |
28231537392ca622cd7f9715da2adf746757886e28de9bef219b70e202e4b946
|