Package com.jalios.jcms.fileprocessor.ui
Class FileProcessorUIUtil
- java.lang.Object
-
- com.jalios.jcms.fileprocessor.ui.FileProcessorUIUtil
-
public class FileProcessorUIUtil extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
ICON_ERROR
static java.lang.String
ICON_EVENTS
static java.lang.String
ICON_EXTENSIONS
static java.lang.String
ICON_FILE_BLACKLISTED
static java.lang.String
ICON_FILE_INDEXED
static java.lang.String
ICON_FILE_PARTIALLY_BLACKLISTED
static java.lang.String
ICON_FILE_STATUS
static java.lang.String
ICON_GLOBAL_REPORT
static java.lang.String
ICON_IGNORED
static java.lang.String
ICON_OK
static java.lang.String
ICON_POSTPONED
static java.lang.String
ICON_PROCESSOR
-
Constructor Summary
Constructors Constructor Description FileProcessorUIUtil()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.lang.String
getDisplayPercent(int part, int all)
static java.lang.String
getFileTypeIcon(java.lang.String filename, java.lang.String userLang)
Method to get file type icon when possible.static java.lang.String
getFileTypeIconFromExtension(java.lang.String extension, java.lang.String userLang)
Method to get file type icon when possible.static java.lang.String
getStatusIconHtml(FileProcessingLog log, java.lang.String userLang)
Retrieve the HTML to use for the specified log's status representationstatic java.lang.String
getStatusIconHtml(ProcessingStatus status, java.lang.String userLang)
Retrieve the HTML to use for the specified status representationstatic java.lang.String
getStatusIconName(ProcessingStatus status)
Retrieve the icon name to use for the specified status representation
-
-
-
Field Detail
-
ICON_FILE_BLACKLISTED
public static java.lang.String ICON_FILE_BLACKLISTED
-
ICON_FILE_INDEXED
public static java.lang.String ICON_FILE_INDEXED
-
ICON_FILE_PARTIALLY_BLACKLISTED
public static java.lang.String ICON_FILE_PARTIALLY_BLACKLISTED
-
ICON_OK
public static java.lang.String ICON_OK
-
ICON_ERROR
public static java.lang.String ICON_ERROR
-
ICON_IGNORED
public static java.lang.String ICON_IGNORED
-
ICON_POSTPONED
public static java.lang.String ICON_POSTPONED
-
ICON_GLOBAL_REPORT
public static java.lang.String ICON_GLOBAL_REPORT
-
ICON_FILE_STATUS
public static java.lang.String ICON_FILE_STATUS
-
ICON_PROCESSOR
public static java.lang.String ICON_PROCESSOR
-
ICON_EXTENSIONS
public static java.lang.String ICON_EXTENSIONS
-
ICON_EVENTS
public static java.lang.String ICON_EVENTS
-
-
Method Detail
-
getStatusIconName
public static java.lang.String getStatusIconName(ProcessingStatus status)
Retrieve the icon name to use for the specified status representation- Parameters:
status
- the ProcessingStatus to represent as an icon- Returns:
- a path relative to the webapp root or null if no icon match the specified status.
-
getStatusIconHtml
public static java.lang.String getStatusIconHtml(ProcessingStatus status, java.lang.String userLang)
Retrieve the HTML to use for the specified status representation- Parameters:
status
- the ProcessingStatus to represent as an iconuserLang
- the ISO-639 user language in which to perform I18N- Returns:
- a HTML img tag with proper icon and I18N
-
getStatusIconHtml
public static java.lang.String getStatusIconHtml(FileProcessingLog log, java.lang.String userLang)
Retrieve the HTML to use for the specified log's status representation- Parameters:
log
- the FileProcessingLog to represent as an iconuserLang
- the ISO-639 user language in which to perform I18N- Returns:
- a HTML img tag with proper icon and I18N
-
getFileTypeIcon
public static java.lang.String getFileTypeIcon(java.lang.String filename, java.lang.String userLang)
Method to get file type icon when possible.- Parameters:
filename
- or part of the filename ending with current extension.userLang
- the ISO-639 user language in which to perform I18N- Returns:
- the complete html sequence to display the icon
-
getFileTypeIconFromExtension
public static java.lang.String getFileTypeIconFromExtension(java.lang.String extension, java.lang.String userLang)
Method to get file type icon when possible.- Parameters:
extension
- generic file extensionuserLang
- the ISO-639 user language in which to perform I18N- Returns:
- the complete html sequence to display the icon
-
getDisplayPercent
public static java.lang.String getDisplayPercent(int part, int all)
-
-