org.broadleafcommerce.core.order.domain
Class OrderPersistedEntityListener

java.lang.Object
  extended by org.broadleafcommerce.core.order.domain.OrderPersistedEntityListener

public class OrderPersistedEntityListener
extends Object

The main function of this entity listener is to publish a Spring event that the customer has been persisted. This is necessary in order to update the current order in the application

Author:
Phillip Verheyden (phillipuniverse)
See Also:
ApplicationEventPublisher#publishEvent(org.springframework.context.ApplicationEvent)}, OrderPersistedEvent}, org.broadleafcommerce.core.web.order.CartStateRefresher}, org.broadleafcommerce.core.web.order.CartState}

Constructor Summary
OrderPersistedEntityListener()
           
 
Method Summary
 void customerUpdated(Object entity)
          Invoked on both the PostPersist and PostUpdate.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OrderPersistedEntityListener

public OrderPersistedEntityListener()
Method Detail

customerUpdated

public void customerUpdated(Object entity)
Invoked on both the PostPersist and PostUpdate. The default implementation is to simply publish a Spring event to the ApplicationContext to allow an event listener to respond appropriately (like resetting the current cart in CartState)

Parameters:
entity - the newly-persisted Order
See Also:
OrderPersistedEvent


Copyright © 2013. All Rights Reserved.