Class CartStateInterceptor

java.lang.Object
org.broadleafcommerce.core.web.order.security.CartStateInterceptor
All Implemented Interfaces:
org.springframework.web.context.request.WebRequestInterceptor

public class CartStateInterceptor extends Object implements org.springframework.web.context.request.WebRequestInterceptor
Interceptor responsible for putting the current cart on the request. Carts are defined in BLC as an Order with a status of IN_PROCESS. This interceptor should go after CustomerStateInterceptor since it relies on CustomerState.

Note that in servlet applications you should be using CartStateFilter

Author:
Phillip Verheyden
  • Field Details

  • Constructor Details

    • CartStateInterceptor

      public CartStateInterceptor()
  • Method Details

    • preHandle

      public void preHandle(org.springframework.web.context.request.WebRequest request) throws Exception
      Specified by:
      preHandle in interface org.springframework.web.context.request.WebRequestInterceptor
      Throws:
      Exception
    • postHandle

      public void postHandle(org.springframework.web.context.request.WebRequest request, org.springframework.ui.ModelMap model) throws Exception
      Specified by:
      postHandle in interface org.springframework.web.context.request.WebRequestInterceptor
      Throws:
      Exception
    • afterCompletion

      public void afterCompletion(org.springframework.web.context.request.WebRequest request, Exception ex) throws Exception
      Specified by:
      afterCompletion in interface org.springframework.web.context.request.WebRequestInterceptor
      Throws:
      Exception