Class CartOperationExceptionAdvisor
- java.lang.Object
-
- com.broadleafcommerce.cartoperation.web.endpoint.exception.CartOperationExceptionAdvisor
-
@RestControllerAdvice(annotations=org.springframework.web.bind.annotation.ResponseBody.class) public class CartOperationExceptionAdvisor extends Object
General exception handler registry for handlers not exclusive to a single controller.- Author:
- Chad Harchar (charchar)
-
-
Constructor Summary
Constructors Constructor Description CartOperationExceptionAdvisor(com.fasterxml.jackson.databind.ObjectMapper mapper)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError>
authenticationRequiredException(AuthenticationRequiredException ex, org.springframework.web.context.request.WebRequest request)
org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError>
bulkAddToCartLimitExceededException(BulkAddToCartLimitExceededException ex, org.springframework.web.context.request.WebRequest request)
org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError>
cartItemValidationException(CartItemValidationException ex, org.springframework.web.context.request.WebRequest request)
protected com.fasterxml.jackson.databind.ObjectMapper
getMapper()
org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError>
handleAddCodeException(AddCodeException ex, org.springframework.web.context.request.WebRequest request)
org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError>
handleAddPaymentException(AddPaymentException ex, org.springframework.web.context.request.WebRequest request)
org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError>
handleCartNotFoundException(CartNotFoundException ex, org.springframework.web.context.request.WebRequest request)
org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError>
handleCartValidationException(CartValidationException ex, org.springframework.web.context.request.WebRequest request)
org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError>
handleCartVersionRequiredException(CartVersionRequiredException ex, org.springframework.web.context.request.WebRequest request)
org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError>
handleGuestCartOnlyException(GuestCartOnlyException ex, org.springframework.web.context.request.WebRequest request)
org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError>
handleGuestTokenDisabledException(GuestTokenDisabledException ex, org.springframework.web.context.request.WebRequest request)
org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError>
handleGuestTokenRequiredException(GuestTokenRequiredException ex, org.springframework.web.context.request.WebRequest request)
org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError>
handleGuestTokenValidationException(GuestTokenValidationException ex, org.springframework.web.context.request.WebRequest request)
org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError>
handleInvalidAddPaymentRequestException(InvalidAddPaymentRequestException ex, org.springframework.web.context.request.WebRequest request)
org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError>
handleInvalidUpdatePaymentRequestException(InvalidUpdatePaymentRequestException ex, org.springframework.web.context.request.WebRequest request)
org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError>
handleProviderApiError(ProviderApiException ex, org.springframework.web.context.request.WebRequest request)
protected void
logDebug(Exception ex, org.springframework.web.context.request.WebRequest request)
protected void
logError(Exception ex, org.springframework.web.context.request.WebRequest request)
org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError>
overridePriceException(OverridePriceException ex, org.springframework.web.context.request.WebRequest request)
org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError>
rejectedItemMergeException(RejectedItemMergeException ex, org.springframework.web.context.request.WebRequest request)
org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError>
staleCartException(StaleCartException ex, org.springframework.web.context.request.WebRequest request)
org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError>
transferCartTokenParseException(TransferCartTokenParseException ex, org.springframework.web.context.request.WebRequest request)
-
-
-
Method Detail
-
handleCartNotFoundException
@ExceptionHandler public org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError> handleCartNotFoundException(CartNotFoundException ex, org.springframework.web.context.request.WebRequest request)
-
handleGuestCartOnlyException
@ExceptionHandler public org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError> handleGuestCartOnlyException(GuestCartOnlyException ex, org.springframework.web.context.request.WebRequest request)
-
handleGuestTokenDisabledException
@ExceptionHandler public org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError> handleGuestTokenDisabledException(GuestTokenDisabledException ex, org.springframework.web.context.request.WebRequest request)
-
handleGuestTokenRequiredException
@ExceptionHandler public org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError> handleGuestTokenRequiredException(GuestTokenRequiredException ex, org.springframework.web.context.request.WebRequest request)
-
handleGuestTokenValidationException
@ExceptionHandler public org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError> handleGuestTokenValidationException(GuestTokenValidationException ex, org.springframework.web.context.request.WebRequest request)
-
handleAddCodeException
@ExceptionHandler public org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError> handleAddCodeException(AddCodeException ex, org.springframework.web.context.request.WebRequest request)
-
handleAddPaymentException
@ExceptionHandler public org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError> handleAddPaymentException(AddPaymentException ex, org.springframework.web.context.request.WebRequest request)
-
handleInvalidAddPaymentRequestException
@ExceptionHandler public org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError> handleInvalidAddPaymentRequestException(InvalidAddPaymentRequestException ex, org.springframework.web.context.request.WebRequest request)
-
handleInvalidUpdatePaymentRequestException
@ExceptionHandler public org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError> handleInvalidUpdatePaymentRequestException(InvalidUpdatePaymentRequestException ex, org.springframework.web.context.request.WebRequest request)
-
handleCartValidationException
@ExceptionHandler public org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError> handleCartValidationException(CartValidationException ex, org.springframework.web.context.request.WebRequest request)
-
handleCartVersionRequiredException
@ExceptionHandler public org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError> handleCartVersionRequiredException(CartVersionRequiredException ex, org.springframework.web.context.request.WebRequest request)
-
overridePriceException
@ExceptionHandler public org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError> overridePriceException(OverridePriceException ex, org.springframework.web.context.request.WebRequest request)
-
cartItemValidationException
@ExceptionHandler public org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError> cartItemValidationException(CartItemValidationException ex, org.springframework.web.context.request.WebRequest request)
-
handleProviderApiError
@ExceptionHandler public org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError> handleProviderApiError(ProviderApiException ex, org.springframework.web.context.request.WebRequest request)
-
staleCartException
@ExceptionHandler public org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError> staleCartException(StaleCartException ex, org.springframework.web.context.request.WebRequest request)
-
transferCartTokenParseException
@ExceptionHandler public org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError> transferCartTokenParseException(TransferCartTokenParseException ex, org.springframework.web.context.request.WebRequest request)
-
authenticationRequiredException
@ExceptionHandler public org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError> authenticationRequiredException(AuthenticationRequiredException ex, org.springframework.web.context.request.WebRequest request)
-
bulkAddToCartLimitExceededException
@ExceptionHandler public org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError> bulkAddToCartLimitExceededException(BulkAddToCartLimitExceededException ex, org.springframework.web.context.request.WebRequest request)
-
rejectedItemMergeException
@ExceptionHandler public org.springframework.http.ResponseEntity<com.broadleafcommerce.common.error.ApiError> rejectedItemMergeException(RejectedItemMergeException ex, org.springframework.web.context.request.WebRequest request)
-
logDebug
protected void logDebug(Exception ex, org.springframework.web.context.request.WebRequest request)
-
logError
protected void logError(Exception ex, org.springframework.web.context.request.WebRequest request)
-
getMapper
protected com.fasterxml.jackson.databind.ObjectMapper getMapper()
-
-