public class RecognizerFileTypeMap
extends javax.activation.FileTypeMap
| Constructor and Description |
|---|
RecognizerFileTypeMap()
Creates a new instance
No Recognizer will be used to determine the
content type of the file (#getContentType will always
return 'application/octet-stream'.
|
RecognizerFileTypeMap(Recognizer detector)
Creates a new instance.
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getContentType(java.io.File file)
Return the base MIME Type of this data.
|
java.lang.String |
getContentType(java.lang.String filename)
Return the base MIME Type of this data.
|
Recognizer |
getRecognizer()
Returns the Recognizer that will be
used for determining the content type of the file.
|
void |
setRecognizer(Recognizer detector)
Sets the Recognizer that will be
used for determining the content type of the file.
|
public RecognizerFileTypeMap()
public RecognizerFileTypeMap(Recognizer detector)
public void setRecognizer(Recognizer detector)
public Recognizer getRecognizer()
public java.lang.String getContentType(java.io.File file)
getContentType in class javax.activation.FileTypeMappublic java.lang.String getContentType(java.lang.String filename)
getContentType in class javax.activation.FileTypeMap