Package com.github.javaparser
Class Problem
- java.lang.Object
-
- com.github.javaparser.Problem
-
public class Problem extends Object
A problem that was encountered during parsing.
-
-
Field Summary
Fields Modifier and Type Field Description static Comparator<Problem>
PROBLEM_BY_BEGIN_POSITION
Sorts problems on position.
-
Constructor Summary
Constructors Constructor Description Problem(String message, TokenRange location, Throwable cause)
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description Optional<Throwable>
getCause()
Optional<TokenRange>
getLocation()
String
getMessage()
Optional<TokenRange>
getRange()
Deprecated.use getLocation()String
getVerboseMessage()
String
toString()
-
-
-
Field Detail
-
PROBLEM_BY_BEGIN_POSITION
public static Comparator<Problem> PROBLEM_BY_BEGIN_POSITION
Sorts problems on position.
-
-
Constructor Detail
-
Problem
public Problem(String message, TokenRange location, Throwable cause)
-
-
Method Detail
-
getMessage
public String getMessage()
- Returns:
- the message that was passed into the constructor.
-
getVerboseMessage
public String getVerboseMessage()
- Returns:
- the message plus location information.
-
getLocation
public Optional<TokenRange> getLocation()
- Returns:
- the location that was passed into the constructor.
-
getRange
@Deprecated public Optional<TokenRange> getRange()
Deprecated.use getLocation()
-
-