mailcap - pydoc - phpman

Look up a command

 

Markdown Format | JSON API | MCP Server Tool


Help on module mailcap:

NAME
    mailcap - Mailcap file handling.  See RFC 1524.

MODULE REFERENCE
    https://docs.python.org/3.10/library/mailcap.html

    The following documentation is automatically generated from the Python
    source files.  It may be incomplete, incorrect or include features that
    are considered implementation detail and may vary between Python
    implementations.  When in doubt, consult the module reference at the
    location listed above.

FUNCTIONS
    findmatch(caps, MIMEtype, key='view', filename='/dev/null', plist=[])
        Find a match for a mailcap entry.

        Return a tuple containing the command line, and the mailcap entry
        used; (None, None) if no match is found.  This may invoke the
        'test' command of several matching entries before deciding which
        entry to use.

    getcaps()
        Return a dictionary containing the mailcap database.

        The dictionary maps a MIME type (in all lowercase, e.g. 'text/plain')
        to a list of dictionaries corresponding to mailcap entries.  The list
        collects all the entries for that MIME type from all available mailcap
        files.  Each dictionary contains key-value pairs for that MIME type,
        where the viewing command is stored with the key "view".

DATA
    __all__ = ['getcaps', 'findmatch']

FILE
    /usr/lib/python3.10/mailcap.py



Generated by phpMan Author: Che Dong Under GNU General Public License
2026-06-02 05:14 @216.73.216.198 CrawledBy Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)
Valid XHTML 1.0 TransitionalValid CSS!