Elexis: Das führende OpenSource-Arztpraxisprogamm
im deutschsprachigen Raum
Java doc für Elexis version 2.1.7.dev vom 01.09.2013

ch.rgw.tools
Class MimeTool

java.lang.Object
  extended by ch.rgw.tools.MimeTool

public class MimeTool
extends java.lang.Object


Constructor Summary
MimeTool()
           
 
Method Summary
static java.lang.String getExtension(java.lang.String mimetype)
          find the file extension for a given mimetype.
static java.lang.String getMimeType(java.lang.String ext)
          find the mimetype for a given extension
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MimeTool

public MimeTool()
Method Detail

getMimeType

public static java.lang.String getMimeType(java.lang.String ext)
find the mimetype for a given extension

Parameters:
ext - an extension with or without dot. Case doesn't matter
Returns:
the matching mimetype or application/octet-stream if none was found, or the empty string if ext was null

getExtension

public static java.lang.String getExtension(java.lang.String mimetype)
find the file extension for a given mimetype. If more than one extension is known for a mimetyoe, only the first one will be chosen

Parameters:
mimetype - a mimetype. Case doesn't matter
Returns:
the matching extension or the empty string if none was found

Elexis: Das führende OpenSource-Arztpraxisprogamm
im deutschsprachigen Raum
Java doc für Elexis version 2.1.7.dev vom 01.09.2013