-
- All Implemented Interfaces:
public final class MimeTypesConfig
Configures static files Mime Types based on file extensions.
-
-
Constructor Summary
Constructors Constructor Description MimeTypesConfig()
-
Method Summary
Modifier and Type Method Description final Map<String, String>
getMapping()
final Unit
add(ContentType contentType)
Adds a known content type to this configuration. final Unit
add(ContentType contentType, String extensions)
Adds a MimeType for custom file extensions. final Unit
add(String mimeType, String extensions)
Adds a MimeType for custom file extensions. String
toString()
-
-
Method Detail
-
getMapping
final Map<String, String> getMapping()
-
add
final Unit add(ContentType contentType)
Adds a known content type to this configuration.
- Parameters:
contentType
- the content type to add
-
add
final Unit add(ContentType contentType, String extensions)
Adds a MimeType for custom file extensions.
- Parameters:
contentType
- the content type to addextensions
- the extensions to use the given content type
-
add
final Unit add(String mimeType, String extensions)
Adds a MimeType for custom file extensions.
- Parameters:
mimeType
- the mime type to addextensions
- the extensions to use the given mime type
-
-
-
-