public class Formatizer extends Object
Modifier and Type | Field and Description |
---|---|
static URI |
GENERIC_UNKNOWN
The generic unknown format URI.
|
Constructor and Description |
---|
Formatizer() |
Modifier and Type | Method and Description |
---|---|
static URI |
buildUri(String pre,
String post)
Builds an URI as `start+end` without caring about an exception.
|
static URI |
getFormatFromExtension(String extension)
Gets the format given a file extension.
|
static URI |
getFormatFromMime(String mime)
Gets the format given a mime type.
|
static URI |
guessFormat(File file)
Guess format given a file.
|
public static URI GENERIC_UNKNOWN
public static URI guessFormat(File file)
file
- the filepublic static URI getFormatFromMime(String mime)
mime
- the mime typepublic static URI getFormatFromExtension(String extension)
extension
- the file extensionCopyright © 2014. All rights reserved.