Class QueryValidationException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
in.co.akshitbansal.springwebquery.exception.QueryException
in.co.akshitbansal.springwebquery.exception.QueryValidationException
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
QueryFieldValidationException
Exception thrown when an API consumer provides an invalid RSQL query,
sorting request, or filter parameters.
This exception indicates that the request itself is malformed or violates configured validation rules (e.g., filtering on a non-filterable field, using a disallowed operator, or providing invalid RSQL syntax).
This exception is intended to be caught and returned as a 4xx client error to the consumer.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionQueryValidationException(String message) Constructs a new query validation exception with the specified detail message.QueryValidationException(String message, Throwable cause) Constructs a new query validation exception with the specified detail message and cause. -
Method Summary
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
QueryValidationException
Constructs a new query validation exception with the specified detail message.- Parameters:
message- the detail message explaining the reason for the validation failure
-
QueryValidationException
Constructs a new query validation exception with the specified detail message and cause.- Parameters:
message- the detail message explaining the reason for the validation failurecause- the underlying cause of the validation failure (e.g.,RSQLParserException)
-