fi.evolver.basics.spring.http.exception.HttpBadRequestException Maven / Gradle / Ivy
package fi.evolver.basics.spring.http.exception;
import org.springframework.http.HttpStatus;
import org.springframework.web.bind.annotation.ResponseStatus;
import fi.evolver.utils.format.FormatUtils;
@ResponseStatus(code = HttpStatus.BAD_REQUEST)
public class HttpBadRequestException extends RuntimeException {
private static final long serialVersionUID = 1L;
public HttpBadRequestException(String message, Object... args) {
super(FormatUtils.format(message, args));
}
public HttpBadRequestException() {
this("Bad request");
}
@Override
public String toString() {
return getMessage();
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy