Package de.uka.ipd.sdq.errorhandling
Class SeverityAndIssue
- java.lang.Object
-
- de.uka.ipd.sdq.errorhandling.SeverityAndIssue
-
- All Implemented Interfaces:
Comparable<SeverityAndIssue>
public class SeverityAndIssue extends Object implements Comparable<SeverityAndIssue>
Issue combined with a severity level. Used to record and report issues to the user using theIssuesDialog.
-
-
Constructor Summary
Constructors Constructor Description SeverityAndIssue(SeverityEnum error, String message, Object element, String objectResourceName)Create a new instance.SeverityAndIssue(SeverityEnum error, String message, EObject element)Create a new instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intcompareTo(SeverityAndIssue o)StringgetDetails()ObjectgetElement()May be null.SeverityEnumgetError()StringgetMessage()StringgetResourceName()Return the resource name or an empty String if thisSeverityAndIssuehas no element.
-
-
-
Constructor Detail
-
SeverityAndIssue
public SeverityAndIssue(SeverityEnum error, String message, EObject element)
Create a new instance.- Parameters:
error- Severity of the issue.message- Description of the issue.element- Element causing the issue (if applicable).
-
SeverityAndIssue
public SeverityAndIssue(SeverityEnum error, String message, Object element, String objectResourceName)
Create a new instance.- Parameters:
error- Severity of the issue.message- Description of the issue.element- Element causing the issue (if applicable).objectResourceName- Name of the resource containing the object (if the element is not anEObject).
-
-
Method Detail
-
getMessage
public String getMessage()
- Returns:
- The issue message.
-
getDetails
public String getDetails()
- Returns:
- Details on the issue's message.
-
getElement
public Object getElement()
May be null.- Returns:
- The Object or null.
-
getResourceName
public String getResourceName()
Return the resource name or an empty String if thisSeverityAndIssuehas no element.- Returns:
-
getError
public SeverityEnum getError()
-
compareTo
public int compareTo(SeverityAndIssue o)
- Specified by:
compareToin interfaceComparable<SeverityAndIssue>
-
-