|
|
|
|
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.torweg.pulse.configuration.AbstractConfigBean
org.torweg.pulse.util.MimeMap
public final class MimeMap
a mapping of file extensions to MIME types.
| Field Summary | |
|---|---|
static java.lang.String |
UNKNOWN_MIME_TYPE
the MIME-type used for unknown MIME-types. |
| Constructor Summary | |
|---|---|
MimeMap()
Deprecated. |
|
| Method Summary | |
|---|---|
static MimeMap |
getInstance()
gives access to an initialised MimeMap. |
java.lang.String |
getMimeType(java.io.File f)
returns the MIME-type for the given file. |
java.lang.String |
getMimeType(java.lang.String fileName)
returns the MIME-type for the given file name. |
java.lang.String |
getMimeType(java.net.URI uri)
returns the MIME-type for the given URI. |
java.lang.String |
getMimeType(VirtualFile f)
returns the MIME-type for the given file. |
java.lang.String |
getMimeTypeByExtension(java.lang.String ext)
returns the MIME-type for the given extension. |
void |
init(org.jdom.Element conf)
initialises the MimeMap from XML. |
| Methods inherited from class org.torweg.pulse.configuration.AbstractConfigBean |
|---|
buildClass, buildInstance, lastModified, setLastModified |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String UNKNOWN_MIME_TYPE
| Constructor Detail |
|---|
@Deprecated public MimeMap()
To get a working instance of MimeMap use
getInstance().
| Method Detail |
|---|
public java.lang.String getMimeTypeByExtension(java.lang.String ext)
If the MIME-type is unknown, it will return
ext - the extension
public java.lang.String getMimeType(java.net.URI uri)
uri - the URI
public java.lang.String getMimeType(java.io.File f)
f - the file
public java.lang.String getMimeType(java.lang.String fileName)
fileName - the file name
public java.lang.String getMimeType(VirtualFile f)
f - the file
public void init(org.jdom.Element conf)
MimeMap from XML.
conf - the configuration XMLConfigBean.init(org.jdom.Element)public static MimeMap getInstance()
MimeMap.
MimeMap
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||