Package dk.netarkivet.common.utils
Class Notifications
- java.lang.Object
-
- dk.netarkivet.common.utils.Notifications
-
- Direct Known Subclasses:
EMailNotifications
,PrintNotifications
,RememberNotifications
public abstract class Notifications extends Object
This class encapsulates reacting to a serious error or warning message.
-
-
Constructor Summary
Constructors Constructor Description Notifications()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description void
notify(String message, NotificationType eventType)
Notify about an event.abstract void
notify(String message, NotificationType eventType, Throwable e)
Notifies about an event including an exception.
-
-
-
Method Detail
-
notify
public void notify(String message, NotificationType eventType)
Notify about an event. This is the same as callingnotify(String, NotificationType, Throwable)
with null as the second parameter.- Parameters:
message
- The error message to notify about.
-
notify
public abstract void notify(String message, NotificationType eventType, Throwable e)
Notifies about an event including an exception.- Parameters:
message
- The message to notify about.eventType
- The type of evente
- An exception related to the event, if not the event itself May be null for no exception.
-
-