MimeTypeDictionary
in package
FinalYes
MIME type, file extension, and compression lookup helper.
Tags
Table of Contents
Constants
- FILE_MIME : mixed = __DIR__ . '/../mimeTypes.xml'
Methods
- guessCompressions() : string
- guessExtension() : string
- guessMime() : string
- isHtml() : bool
- isText() : bool
- isXml() : bool
- matchesMime() : bool
Constants
FILE_MIME
public
mixed
FILE_MIME
= __DIR__ . '/../mimeTypes.xml'
Methods
guessCompressions()
public
static guessCompressions(string $mime) : string
Parameters
- $mime : string
Return values
stringguessExtension()
public
static guessExtension(string $mime) : string
Parameters
- $mime : string
Return values
stringguessMime()
public
static guessMime(string $extension) : string
Parameters
- $extension : string
Return values
stringisHtml()
public
static isHtml(string $type) : bool
Parameters
- $type : string
Return values
boolisText()
public
static isText(string $type) : bool
Parameters
- $type : string
Return values
boolisXml()
public
static isXml(string $type) : bool
Parameters
- $type : string
Return values
boolmatchesMime()
public
static matchesMime(string $extension, string $testMime) : bool
Parameters
- $extension : string
- $testMime : string