|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.googlecode.fascinator.common.MimeTypeUtil
public class MimeTypeUtil
Utility class to determine MIME type
| Field Summary | |
|---|---|
static String |
DEFAULT_MIME_TYPE
Default Mime Type |
| Constructor Summary | |
|---|---|
MimeTypeUtil()
|
|
| Method Summary | |
|---|---|
static String |
getMimeType(byte[] bytes,
String filename)
Gets the MIME type for the specified byte array and filename |
static String |
getMimeType(File file)
Gets the MIME type for the specified file |
static String |
getMimeType(InputStream in)
Gets the MIME type for the specified input stream |
static String |
getMimeType(String filename)
Gets the MIME type for the specified file name |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String DEFAULT_MIME_TYPE
| Constructor Detail |
|---|
public MimeTypeUtil()
| Method Detail |
|---|
public static String getMimeType(String filename)
filename - a file name
public static String getMimeType(File file)
file - a file
public static String getMimeType(InputStream in)
in - an input stream
public static String getMimeType(byte[] bytes,
String filename)
bytes - a byte arrayfilename - a file name
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||