/**
* Registers type converters.
*/
public static void registerTypeConverter() {
TypeConverterManagerBean typeConverterManagerBean = TypeConverterManager.getDefaultTypeConverterManager();
typeConverterManagerBean.register(FileUpload.class, new FileUploadConverter());
FileConverter fileConverter = (FileConverter) typeConverterManagerBean.lookup(File.class);
fileConverter.registerAddonConverter(new FileUploadToFileTypeConverter());
}