public abstract class FileTypeMap extends Object
FileTypeMap,
FileDataSource,
MimetypesFileTypeMap| Constructor and Description |
|---|
FileTypeMap()
The default constructor.
|
| Modifier and Type | Method and Description |
|---|---|
abstract String |
getContentType(File file)
Return the type of the file object.
|
abstract String |
getContentType(String filename)
Return the type of the file passed in.
|
static FileTypeMap |
getDefaultFileTypeMap()
Return the default FileTypeMap for the system.
|
static void |
setDefaultFileTypeMap(FileTypeMap fileTypeMap)
Sets the default FileTypeMap for the system.
|
public abstract String getContentType(File file)
file - A file to be typed.public abstract String getContentType(String filename)
filename - the pathname of the file.public static void setDefaultFileTypeMap(FileTypeMap fileTypeMap)
SecurityException - if the caller doesn't have permission
to change the defaultfileTypeMap - The FileTypeMap.public static FileTypeMap getDefaultFileTypeMap()
MimetypesFileTypeMap.setDefaultFileTypeMap(javax.activation.FileTypeMap)aicas GmbH, Karlsruhe, Germany —www.aicas.com
Copyright © 2001-2019 aicas GmbH. All Rights Reserved.