@OpenApiAll
public class NotificationManager
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
(package private) static class |
NotificationManager.QueuedNotificationType
Types of de-referred notification messages
|
Modifier | Constructor and Description |
---|---|
protected |
NotificationManager()
Creates new Notification manager instance.
|
Modifier and Type | Method and Description |
---|---|
NotificationViewBuilder |
getApplicationNotificationsBuilder()
Returns builder that creates and displays application notifications
|
NotificationViewConfig |
getConfig(Notification notification)
Helper method that returns predefined display parameters determined by notification severity level.
|
NotificationViewBuilder |
getContainerNotificationsBuilder()
Returns builder that creates and displays container notifications
|
NotificationViewConfig |
getErrorConfig()
Returns display parameters for notification with severity error
|
NotificationViewConfig |
getInfoConfig()
Returns display parameters for notification with severity info
|
static NotificationManager |
getInstance()
Returns single Notification manger instance
|
NotificationViewConfig |
getWarningConfig()
Returns display parameters for notification with severity warning
|
void |
hideNotifications(java.lang.String notificationID)
Hides notifications with specified id
|
boolean |
isNotificationVisible(java.lang.String notificationID)
Returns true if notification with specified id is shown
|
void |
logHyperlinkedTextNotifications(java.lang.String text,
java.util.Map<java.lang.String,java.lang.Runnable> callbacks)
Logs hyperlinked text to Notification window without displaying balloon message.
|
void |
openNotificationWindow(Notification notification,
boolean openWindow)
Shows notification in notification window
|
void |
setApplicationNotificationsBuilder(NotificationViewBuilder applicationNotificationsBuilder)
Sets builder that creates and displays application notifications
|
void |
setContainerNotificationsBuilder(NotificationViewBuilder containerNotificationsBuilder)
Sets builder that creates and displays container notifications
|
void |
showNotification(Notification notification)
Shows application level notification in right bottom corner with default display parameters.
|
void |
showNotification(Notification notification,
java.awt.Component owner)
Shows application or container level notification with default display parameters.
|
void |
showNotification(Notification notification,
java.awt.Component owner,
NotificationViewConfig config)
Shows application or container level notification with specified display parameters.
|
void |
showNotification(Notification notification,
NotificationViewConfig config)
Shows application level notification in right bottom corner with display parameters specified in config object.
|
protected NotificationManager()
public static NotificationManager getInstance()
public void openNotificationWindow(Notification notification, boolean openWindow)
notification
- notificationopenWindow
- flag, if true opens notification windowpublic void showNotification(Notification notification)
notification
- notification to showpublic void showNotification(Notification notification, NotificationViewConfig config)
notification
- notification to showconfig
- notification display parameterspublic void showNotification(Notification notification, @CheckForNull java.awt.Component owner)
notification
- notification to showowner
- notification display containerpublic void showNotification(Notification notification, @CheckForNull java.awt.Component owner, NotificationViewConfig config)
notification
- notification to showowner
- notification display containerconfig
- notification display parameterspublic void hideNotifications(java.lang.String notificationID)
notificationID
- notification idpublic boolean isNotificationVisible(java.lang.String notificationID)
notificationID
- notification idpublic void logHyperlinkedTextNotifications(java.lang.String text, java.util.Map<java.lang.String,java.lang.Runnable> callbacks)
text
- text with hyper links.callbacks
- callbacks that will be executed when link in text is selectedpublic NotificationViewBuilder getApplicationNotificationsBuilder()
public void setApplicationNotificationsBuilder(NotificationViewBuilder applicationNotificationsBuilder)
applicationNotificationsBuilder
- builder that creates and displays application notificationspublic NotificationViewBuilder getContainerNotificationsBuilder()
public void setContainerNotificationsBuilder(NotificationViewBuilder containerNotificationsBuilder)
containerNotificationsBuilder
- builder that creates and displays container notificationspublic NotificationViewConfig getErrorConfig()
public NotificationViewConfig getWarningConfig()
public NotificationViewConfig getInfoConfig()
public NotificationViewConfig getConfig(Notification notification)
notification
- notification for which display parameters should be returned