public class XMimeTypeUtils extends Object
Constructor and Description |
---|
XMimeTypeUtils() |
Modifier and Type | Method and Description |
---|---|
static boolean |
containsContentTypes(Collection<?> types,
String... contentTypes) |
static boolean |
containsMediaTypes(Collection<?> types,
String... mediaTypes) |
static String |
getContentType(byte[] data) |
static String |
getContentType(File file) |
static String |
getContentType(InputStream is) |
static String |
getContentType(String filename) |
static Collection<?> |
getContentTypes(byte[] data) |
static Collection<?> |
getContentTypes(File file) |
static Collection<?> |
getContentTypes(InputStream is) |
static Collection<?> |
getContentTypes(String filename) |
static boolean |
isContentType(byte[] data,
String... contentTypes) |
static boolean |
isContentType(File file,
String... contentTypes) |
static boolean |
isContentType(InputStream is,
String... contentTypes) |
static boolean |
isContentType(String filename,
String... contentTypes) |
static boolean |
isMediaTypes(byte[] data,
String mediaTypes) |
static boolean |
isMediaTypes(File file,
String mediaTypes) |
static boolean |
isMediaTypes(InputStream is,
String mediaTypes) |
static boolean |
isMediaTypes(String filename,
String mediaTypes) |
public static String getContentType(InputStream is)
public static String getContentType(byte[] data)
public static Collection<?> getContentTypes(InputStream is)
public static Collection<?> getContentTypes(byte[] data)
public static Collection<?> getContentTypes(String filename)
public static Collection<?> getContentTypes(File file)
public static boolean isContentType(InputStream is, String... contentTypes)
public static boolean isContentType(byte[] data, String... contentTypes)
public static boolean isMediaTypes(InputStream is, String mediaTypes)
public static boolean isMediaTypes(byte[] data, String mediaTypes)
public static boolean containsMediaTypes(Collection<?> types, String... mediaTypes)
public static boolean containsContentTypes(Collection<?> types, String... contentTypes)
Copyright © 2020 XIMA MEDIA GmbH. All rights reserved.