de.cau.cs.kieler.core.ui.errorhandler
Class ModelErrorHandler
java.lang.Object
org.eclipse.ui.statushandlers.AbstractStatusHandler
org.eclipse.ui.statushandlers.WorkbenchErrorHandler
de.cau.cs.kieler.core.ui.errorhandler.GenericErrorHandler
de.cau.cs.kieler.core.ui.errorhandler.ModelErrorHandler
public class ModelErrorHandler
- extends GenericErrorHandler
A StatusHandler that displays error messages for KielerModelException Status
causes at the corresponding Diagram object as a problem marker. Other
exceptions and styles (BLOCK, LOG) are handled like the default Status
handler.
- Rating

Method Summary |
static void |
addMarker(String msg,
EObject target)
Add a problem marker to a given EObject to indicate problems graphically
in the diagram. |
static void |
clearMarker(EObject target)
Remove all custom problem markers from a given EObject to indicate
problems graphically in the diagram. |
void |
handle(StatusAdapter statusAdapter,
int style)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ModelErrorHandler
public ModelErrorHandler()
handle
public void handle(StatusAdapter statusAdapter,
int style)
- Description copied from class:
GenericErrorHandler
-
- Overrides:
handle
in class GenericErrorHandler
addMarker
public static void addMarker(String msg,
EObject target)
throws KielerException
- Add a problem marker to a given EObject to indicate problems graphically
in the diagram. Will silently fail at any errors, e.g. if there is no
graphical editor open corresponding to the object.
- Parameters:
msg
- String message of the markertarget
- target object
- Throws:
KielerException
- if the marker cannot be created
clearMarker
public static void clearMarker(EObject target)
- Remove all custom problem markers from a given EObject to indicate
problems graphically in the diagram. Will silently fail at any errors,
e.g. if there is no graphical editor open corresponding to the object.
- Parameters:
target
- target object