public class AbstractReport extends Object
Constructor and Description |
---|
AbstractReport()
Default constructor with empty message.
|
AbstractReport(String message)
Constructor.
|
AbstractReport(String message,
int severity)
Constructor.
|
AbstractReport(String message,
int severity,
Object... arguments)
Constructor with MessageFormat support.
|
AbstractReport(String message,
Object... arguments)
Constructor with MessageFormat support.
|
AbstractReport(Throwable exception)
Constructor.
|
AbstractReport(Throwable exception,
int severity)
Constructor.
|
AbstractReport(Throwable exception,
String message)
Constructor.
|
AbstractReport(Throwable exception,
String message,
Object... arguments)
Constructor with MessageFormat support.
|
Modifier and Type | Method and Description |
---|---|
Throwable |
getException()
Returns the exception this report is based on, if any.
|
String |
getMessage()
Returns the report message.
|
int |
getSeverity()
Returns the status of this report.
|
boolean |
hasException()
Whether this report is based upon an exception.
|
protected void |
setException(Throwable exception)
Sets the exception this report is based on.
|
protected void |
setMessage(String message)
Sets the report' message.
|
public AbstractReport()
IStatus.ERROR
.public AbstractReport(Throwable exception)
IStatus.ERROR
.exception
- the exception this report is based onpublic AbstractReport(String message)
IStatus.ERROR
.message
- the report messagepublic AbstractReport(String message, Object... arguments)
IStatus.ERROR
.message
- the report messagearguments
- the arguments for the messagepublic AbstractReport(String message, int severity)
message
- the report messageseverity
- the severity of the report specified as an IStatus
severity code.public AbstractReport(String message, int severity, Object... arguments)
message
- the report messageseverity
- the message severityarguments
- the arguments for the messagepublic AbstractReport(Throwable exception, String message)
IStatus.ERROR
.exception
- the exception this report is based onmessage
- the report messagepublic AbstractReport(Throwable exception, String message, Object... arguments)
exception
- the exception this report is based onmessage
- the report messagearguments
- the arguments for the messagepublic AbstractReport(Throwable exception, int severity)
exception
- the exception this report is based onseverity
- the severity of the reportpublic String getMessage()
public boolean hasException()
true
, if this report is based upon an exception, false
otherwisepublic Throwable getException()
null
hasException()
public int getSeverity()
protected void setException(Throwable exception)
exception
- the exception this report is based onhasException()
protected void setMessage(String message)
message
- the report message to setCopyright © 2019. All rights reserved.