ExtensionInterface
in
Interface for Extension objects.
Table of Contents
Methods
- __construct() : mixed
- Constructor.
- getDefaultType() : string
- Returns the file extension's preferred MIME type.
- getTypes() : array<int, string>
- Returns all the MIME types related to the file extension.
Methods
__construct()
Constructor.
public
__construct(string $extension[, MimeMapInterface>|null $mapClass = null ]) : mixed
APIYes
Parameters
- $extension : string
-
A file extension.
- $mapClass : MimeMapInterface>|null = null
-
(Optional) The FQCN of the map class to use.
getDefaultType()
Returns the file extension's preferred MIME type.
public
getDefaultType() : string
APIYes
Tags
Return values
stringgetTypes()
Returns all the MIME types related to the file extension.
public
getTypes() : array<int, string>
APIYes