use of com.vip.saturn.job.console.domain.RestApiErrorResult in project Saturn by vipshop.
the class RestApiExceptionHandlerController method constructErrorResponse.
private ResponseEntity<Object> constructErrorResponse(String errorMsg, HttpStatus status) {
HttpHeaders httpHeaders = new HttpHeaders();
RestApiErrorResult restApiErrorResult = new RestApiErrorResult();
restApiErrorResult.setMessage(errorMsg);
return new ResponseEntity<Object>(restApiErrorResult, httpHeaders, status);
}
use of com.vip.saturn.job.console.domain.RestApiErrorResult in project Saturn by vipshop.
the class AbstractRestController method constructErrorResponse.
private ResponseEntity<Object> constructErrorResponse(String errorMsg, HttpStatus status) {
HttpHeaders httpHeaders = new HttpHeaders();
httpHeaders.setContentType(MediaType.APPLICATION_JSON_UTF8);
RestApiErrorResult restApiErrorResult = new RestApiErrorResult();
restApiErrorResult.setMessage(errorMsg);
return new ResponseEntity<Object>(restApiErrorResult, httpHeaders, status);
}
use of com.vip.saturn.job.console.domain.RestApiErrorResult in project Saturn by vipshop.
the class SaturnJobConsoleExceptionHandlerController method constructErrorResponse.
private ResponseEntity<Object> constructErrorResponse(String errorMsg, HttpStatus status) {
HttpHeaders httpHeaders = new HttpHeaders();
RestApiErrorResult restApiErrorResult = new RestApiErrorResult();
restApiErrorResult.setMessage(errorMsg);
return new ResponseEntity<Object>(restApiErrorResult, httpHeaders, status);
}
Aggregations