public final class MimeUtils extends Object
| Modifier and Type | Method and Description |
|---|---|
static String |
guessExtensionFromMime(String mimeType)
Returns the registered extension for the given MIME type.
|
static String |
guessMimeFromExtension(String extension)
Returns the MIME type for the given extension.
|
static boolean |
hasExtension(String extension)
Returns true if the given extension has a registered MIME type.
|
static boolean |
hasMimeType(String mimeType)
Returns true if the given MIME type has an entry in the map.
|
public static boolean hasMimeType(String mimeType)
mimeType - A MIME type (i.e. text/plain)public static String guessMimeFromExtension(String extension)
extension - A file extension without the leading '.'public static boolean hasExtension(String extension)
extension - A file extension without the leading '.'public static String guessExtensionFromMime(String mimeType)
mimeType - A MIME type (i.e. text/plain)Copyright © 2019. All rights reserved.