java.lang.Object
cloud.piranha.core.impl.DefaultMimeTypeManager
- All Implemented Interfaces:
MimeTypeManager
The default MimeTypeManager implementation.
- Author:
- Manfred Riem ([email protected])
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addMimeType
(String extension, String mimeType) Add the mime type.getMimeType
(String filename) Get the mime type.
-
Constructor Details
-
DefaultMimeTypeManager
public DefaultMimeTypeManager()
-
-
Method Details
-
addMimeType
Description copied from interface:MimeTypeManager
Add the mime type.- Specified by:
addMimeType
in interfaceMimeTypeManager
- Parameters:
extension
- the extension (without the dot).mimeType
- the mime type to return.
-
getMimeType
Description copied from interface:MimeTypeManager
Get the mime type.- Specified by:
getMimeType
in interfaceMimeTypeManager
- Parameters:
filename
- the filename.- Returns:
- the mime type or null if not found.
-