Class MetaErrorListeners
java.lang.Object
com.igormaznitsa.meta.common.exceptions.MetaErrorListeners
Service containing all error listeners for the common module methods and providing their notifications.
- Since:
- 1.0
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic void
Add new fireError listener for global fireError events.static void
clear()
Remove all listeners.static void
Send notifications to all listeners.static boolean
Check that there are registered listeners.static void
Remove listener.
-
Field Details
-
ERROR_LISTENERS
-
-
Constructor Details
-
MetaErrorListeners
private MetaErrorListeners()
-
-
Method Details
-
clear
public static void clear()Remove all listeners.- Since:
- 1.0
-
addErrorListener
Add new fireError listener for global fireError events.- Parameters:
value
- listener to be added- Since:
- 1.0
-
removeErrorListener
Remove listener.- Parameters:
value
- listener to be removed- Since:
- 1.0
-
hasListeners
public static boolean hasListeners()Check that there are registered listeners.- Returns:
- true if presented listeners for global fireError events, false otherwise
- Since:
- 1.0
-
fireError
Send notifications to all listeners.- Parameters:
text
- message texterror
- error object- Since:
- 1.0
-