public final class MediaTypeUtils extends Object
SpeechToText
service.SpeechToText
Modifier and Type | Method and Description |
---|---|
static String |
getMediaTypeFromFile(File file)
Returns the media type for a given file.
|
static boolean |
isValidMediaType(String mediaType)
Checks if the media type is supported by the service.
|
public static String getMediaTypeFromFile(File file)
file
- the file object for which media type needs to be providedpublic static boolean isValidMediaType(String mediaType)
mediaType
- Internet media type for the fileCopyright © 2021 IBM Cloud. All rights reserved.