Olá, está dando vários erros nas interfaces que foi gerada pelo Swagger, no if "getObjectMapper" e no "isPresent()", porque está acontecendo isso?
default ResponseEntity<String> getCargo(@ApiParam(value = "",required=true) @PathVariable("id") Long id) {
if(getObjectMapper().isPresent() && getAcceptHeader().isPresent()) {
if (getAcceptHeader().get().contains("application/json")) {
try {
return new ResponseEntity<>(getObjectMapper().get().readValue("\"\"", String.class), HttpStatus.NOT_IMPLEMENTED);
} catch (IOException e) {
log.error("Couldn't serialize response for content type application/json", e);
return new ResponseEntity<>(HttpStatus.INTERNAL_SERVER_ERROR);
}
}
} else {
log.warn("ObjectMapper or HttpServletRequest not configured in default CargoApi interface so no example is generated");
}