All Downloads are FREE. Search and download functionalities are using the official Maven repository.

handlebars.JavaMicronaut.unsupportedOperationExceptionHandler.mustache Maven / Gradle / Ivy

There is a newer version: 1.0.54
Show newest version
package {{configPackage}};


import io.micronaut.context.annotation.Requires;
import io.micronaut.http.HttpRequest;
import io.micronaut.http.HttpResponse;
import io.micronaut.http.HttpStatus;
import io.micronaut.http.annotation.Produces;
import io.micronaut.http.server.exceptions.ExceptionHandler;
import jakarta.inject.Singleton;

@Produces
@Singleton
@Requires(classes = {UnsupportedOperationException.class, ExceptionHandler.class})
public class UnsupportedOperationExceptionHandler implements ExceptionHandler {

    @Override
    public HttpResponse handle(HttpRequest request, UnsupportedOperationException exception) {
        return HttpResponse.status(HttpStatus.NOT_IMPLEMENTED);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy