|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.eclipse.ocl.examples.modelregistry.ui.ripoffs.StatusInfo
public class StatusInfo
A settable IStatus. Can be an error, warning, info or ok. For error, info and warning states, a message describes the problem.
Field Summary | |
---|---|
static org.eclipse.core.runtime.IStatus |
OK_STATUS
|
Fields inherited from interface org.eclipse.core.runtime.IStatus |
---|
CANCEL, ERROR, INFO, OK, WARNING |
Constructor Summary | |
---|---|
StatusInfo()
Creates a status set to OK (no message) |
|
StatusInfo(java.lang.Exception e)
|
|
StatusInfo(int severity,
java.lang.String message)
Creates a status . |
Method Summary | |
---|---|
org.eclipse.core.runtime.IStatus[] |
getChildren()
Returns always an empty array. |
int |
getCode()
Returns always the error severity. |
java.lang.Throwable |
getException()
Returns always null . |
java.lang.String |
getMessage()
|
java.lang.String |
getPlugin()
|
int |
getSeverity()
|
boolean |
isError()
Returns if the status' severity is ERROR. |
boolean |
isInfo()
Returns if the status' severity is INFO. |
boolean |
isMultiStatus()
Returns always false . |
boolean |
isOK()
Returns if the status' severity is OK. |
boolean |
isWarning()
Returns if the status' severity is WARNING. |
boolean |
matches(int severityMask)
|
void |
setError(java.lang.String errorMessage)
Sets the status to ERROR. |
void |
setInfo(java.lang.String infoMessage)
Sets the status to INFO. |
void |
setOK()
Sets the status to OK. |
void |
setWarning(java.lang.String warningMessage)
Sets the status to WARNING. |
java.lang.String |
toString()
Returns a string representation of the status, suitable for debugging purposes only. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final org.eclipse.core.runtime.IStatus OK_STATUS
Constructor Detail |
---|
public StatusInfo()
public StatusInfo(int severity, java.lang.String message)
severity
- The status severity: ERROR, WARNING, INFO and OK.message
- The message of the status. Applies only for ERROR,
WARNING and INFO.public StatusInfo(java.lang.Exception e)
Method Detail |
---|
public boolean isOK()
isOK
in interface org.eclipse.core.runtime.IStatus
public boolean isWarning()
public boolean isInfo()
public boolean isError()
public java.lang.String getMessage()
getMessage
in interface org.eclipse.core.runtime.IStatus
IStatus.getMessage()
public void setError(java.lang.String errorMessage)
errorMessage
- The error message (can be empty, but not null)public void setWarning(java.lang.String warningMessage)
warningMessage
- The warning message (can be empty, but not null)public void setInfo(java.lang.String infoMessage)
infoMessage
- The info message (can be empty, but not null)public void setOK()
public boolean matches(int severityMask)
matches
in interface org.eclipse.core.runtime.IStatus
public boolean isMultiStatus()
false
.
isMultiStatus
in interface org.eclipse.core.runtime.IStatus
IStatus.isMultiStatus()
public int getSeverity()
getSeverity
in interface org.eclipse.core.runtime.IStatus
public java.lang.String getPlugin()
getPlugin
in interface org.eclipse.core.runtime.IStatus
public java.lang.Throwable getException()
null
.
getException
in interface org.eclipse.core.runtime.IStatus
IStatus.getException()
public int getCode()
getCode
in interface org.eclipse.core.runtime.IStatus
IStatus.getCode()
public org.eclipse.core.runtime.IStatus[] getChildren()
getChildren
in interface org.eclipse.core.runtime.IStatus
IStatus.getChildren()
public java.lang.String toString()
toString
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |