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

io.airlift.airship.shared.VersionConflictExceptionMapper Maven / Gradle / Ivy

package io.airlift.airship.shared;

import javax.ws.rs.core.Response;
import javax.ws.rs.core.Response.Status;
import javax.ws.rs.ext.ExceptionMapper;

public class VersionConflictExceptionMapper implements ExceptionMapper
{
    @Override
    public Response toResponse(VersionConflictException exception)
    {
        return Response.status(Status.CONFLICT)
                .header(exception.getName(), exception.getVersion())
                .build();
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy