class DefaultProblem extends java.lang.Object implements Problem
Problem.Severity| Modifier and Type | Field and Description |
|---|---|
private int |
columnNumber |
private java.lang.Exception |
exception |
private int |
lineNumber |
private java.lang.String |
message |
private Problem.Severity |
severity |
private java.lang.String |
source |
| Constructor and Description |
|---|
DefaultProblem(java.lang.String message,
Problem.Severity severity,
java.lang.String source,
int lineNumber,
int columnNumber,
java.lang.Exception exception)
Creates a new problem with the specified message and exception.
|
| Modifier and Type | Method and Description |
|---|---|
int |
getColumnNumber()
Gets the one-based index of the column containing the problem.
|
java.lang.Exception |
getException()
Gets the exception that caused this problem (if any).
|
int |
getLineNumber()
Gets the one-based index of the line containing the problem.
|
java.lang.String |
getLocation()
Gets the location of the problem.
|
java.lang.String |
getMessage()
Gets the message that describes this problem.
|
Problem.Severity |
getSeverity()
Gets the severity level of this problem.
|
java.lang.String |
getSource()
Gets the hint about the source of the problem.
|
java.lang.String |
toString() |
private final java.lang.String source
private final int lineNumber
private final int columnNumber
private final java.lang.String message
private final java.lang.Exception exception
private final Problem.Severity severity
DefaultProblem(java.lang.String message,
Problem.Severity severity,
java.lang.String source,
int lineNumber,
int columnNumber,
java.lang.Exception exception)
message or exception is requiredmessage - The message describing the problem, may be null.severity - The severity level of the problem, may be null to default to
SettingsProblem.Severity#ERROR.source - A hint about the source of the problem like a file path, may be null.lineNumber - The one-based index of the line containing the problem or -1 if unknown.columnNumber - The one-based index of the column containing the problem or -1 if unknown.exception - The exception that caused this problem, may be null.public java.lang.String getSource()
Problempublic int getLineNumber()
ProblemProblem.getSource().getLineNumber in interface Problempublic int getColumnNumber()
ProblemProblem.getSource().getColumnNumber in interface Problempublic java.lang.String getLocation()
ProblemProblem.getSource(), Problem.getLineNumber() and Problem.getColumnNumber(). The exact syntax of the returned
value is undefined.getLocation in interface Problemnull.public java.lang.Exception getException()
ProblemgetException in interface Problemnull if not applicable.public java.lang.String getMessage()
ProblemgetMessage in interface Problemnull.public Problem.Severity getSeverity()
ProblemgetSeverity in interface Problemnull.public java.lang.String toString()
toString in class java.lang.Object