mimetypes.MimeTypes

class mimetypes.MimeTypes(filenames=(), strict=True)

This class represents a MIME-types database. By default, it provides access to the same database as the rest of this module. The initial database is a copy of that provided by the module, and may be extended by loading additional mime.types-style files into the database using the read() or readfp() methods. The mapping dictionaries may also be cleared before loading additional data if the default data is not desired.

The optional filenames parameter can be used to cause additional files to be loaded “on top” of the default database.

doc_python
2016-10-07 17:37:15
Comments
Leave a Comment

Please login to continue.