Package org.jdesktop.swingx.error
Class ErrorSupport
- java.lang.Object
-
- org.jdesktop.swingx.error.ErrorSupport
-
public class ErrorSupport extends Object
ErrorSupport provides support for managing error listeners.- Author:
- Joshua Marinacci joshua.marinacci@sun.com
- See Also:
ErrorListener
,ErrorEvent
-
-
Constructor Summary
Constructors Constructor Description ErrorSupport(Object source)
Creates a new instance ofErrorSupport
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addErrorListener(ErrorListener listener)
Add an ErrorListenervoid
fireErrorEvent(Throwable throwable)
Report that an error has occuredErrorListener[]
getErrorListeners()
Returns an array of all the listeners which were added to theErrorSupport
object withaddErrorListener()
.void
removeErrorListener(ErrorListener listener)
Remove an error listener
-
-
-
Constructor Detail
-
ErrorSupport
public ErrorSupport(Object source)
Creates a new instance ofErrorSupport
- Parameters:
source
- The object which will fire theErrorEvent
s
-
-
Method Detail
-
addErrorListener
public void addErrorListener(ErrorListener listener)
Add an ErrorListener- Parameters:
listener
- the listener to add
-
removeErrorListener
public void removeErrorListener(ErrorListener listener)
Remove an error listener- Parameters:
listener
- the listener to remove
-
getErrorListeners
public ErrorListener[] getErrorListeners()
Returns an array of all the listeners which were added to theErrorSupport
object withaddErrorListener()
.- Returns:
- all of the
ErrorListener
s added or an empty array if no listeners have been added.
-
-