class ContentNegotiationHandler {

    protected boolean requiresConversion(String sourceMimeType, String targetMimeTypee){
        // if accept is not generic and doesn't correspond to content type, then conversion should happen
        return !(targetMimeTypee == null ||
                "application/json".equalsIgnoreCase(targetMimeTypee) ||
                "application/xml".equalsIgnoreCase(targetMimeTypee) ||
                sourceMimeType.equalsIgnoreCase(targetMimeTypee));
    }

}