Package org.jboss.forge.roaster
Class ParserException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- org.jboss.forge.roaster.ParserException
-
- All Implemented Interfaces:
java.io.Serializable
public class ParserException extends java.lang.RuntimeExceptionParserExceptionis the exception which is thrown if a parsing process fails. The problems occurred during the parsing can be accessed withgetProblems().- Author:
- Lincoln Baxter, III
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description ParserException()Constructs a newParserExceptionwith no problems, anullerror message and anullcause.ParserException(java.lang.String message)Constructs a newParserExceptionwith no problems, the given error message and anullcause.ParserException(java.lang.String message, java.lang.Throwable cause)Constructs a newParserExceptionwith no problems, the given error message and the given cause.ParserException(java.lang.String message, java.util.List<Problem> problems)Constructs a newParserExceptionwith the given problems, the given error message and anullcause.ParserException(java.lang.Throwable cause)Constructs a newParserExceptionwith no problems, anullerror message and the given cause.ParserException(java.util.List<Problem> problems)Constructs a newParserExceptionwith the given problems, a error message constructed from the problems list and anullcause.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.List<Problem>getProblems()Get the problems occurred during a parsing process.
-
-
-
Constructor Detail
-
ParserException
public ParserException()
Constructs a newParserExceptionwith no problems, anullerror message and anullcause.
-
ParserException
public ParserException(java.lang.String message)
Constructs a newParserExceptionwith no problems, the given error message and anullcause.- Parameters:
message- the error message of this exception
-
ParserException
public ParserException(java.lang.Throwable cause)
Constructs a newParserExceptionwith no problems, anullerror message and the given cause.- Parameters:
cause- the cause of this exception
-
ParserException
public ParserException(java.lang.String message, java.lang.Throwable cause)Constructs a newParserExceptionwith no problems, the given error message and the given cause.- Parameters:
message- the error message of this exceptioncause- the cause of this exception
-
ParserException
public ParserException(java.lang.String message, java.util.List<Problem> problems)Constructs a newParserExceptionwith the given problems, the given error message and anullcause.Note that the problems list instance is not copied.
- Parameters:
message- the error message of this exceptionproblems- the problems of this exception
-
ParserException
public ParserException(java.util.List<Problem> problems)
Constructs a newParserExceptionwith the given problems, a error message constructed from the problems list and anullcause.Note that the problems list instance is not copied.
- Parameters:
problems- the problems of this exception
-
-
Method Detail
-
getProblems
public java.util.List<Problem> getProblems()
Get the problems occurred during a parsing process. The returned list is maybe empty but nevernull.- Returns:
- a unmodifiable list of the problems occurred during a parsing process
- See Also:
Collections.unmodifiableList(List)
-
-