Package org.checkerframework.javacutil
Class UserError
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
org.checkerframework.javacutil.UserError
- All Implemented Interfaces:
Serializable
Exception type indicating a mistake by an end user in using the Checker Framework, such as
incorrect command-line arguments.
To indicate a bug in the framework, use BugInCF. To indicate a bug in a checker
implementation, use TypeSystemError.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionConstructs a new CheckerError with the specified detail message.Constructs a new CheckerError with a detail message composed from the given arguments.Constructs a new CheckerError with the specified detail message and cause.Constructs a new CheckerError with the specified cause and with a detail message composed from the given arguments. -
Method Summary
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
UserError
Constructs a new CheckerError with the specified detail message.- Parameters:
message- the detail message
-
UserError
Constructs a new CheckerError with a detail message composed from the given arguments.Beware: if the only argument is a
Throwable, then Java instead selectsUserError(String, Throwable), which usesfmtliterally rather than as a format string, and uses the throwable as the cause. To format a throwable into the detail message, pass it as an explicit cause too, as innew UserError(t, "Cannot read %s", t), or passt.getMessage()as the format argument.- Parameters:
fmt- the format stringargs- the arguments for the format string
-
UserError
Constructs a new CheckerError with the specified detail message and cause.- Parameters:
message- the detail messagecause- the cause
-
UserError
Constructs a new CheckerError with the specified cause and with a detail message composed from the given arguments.- Parameters:
cause- the causefmt- the format stringargs- the arguments for the format string
-