com.google.checkout.handlers
Class CompositeNotificationHandler

java.lang.Object
  extended by com.google.checkout.handlers.CompositeNotificationHandler
All Implemented Interfaces:
NotificationHandler

public class CompositeNotificationHandler
extends java.lang.Object
implements NotificationHandler

Author:
Charles Dang (cdang@google.com)

Constructor Summary
CompositeNotificationHandler()
           
 
Method Summary
 void handle(MerchantInfo mi, CheckoutNotification notification)
          Processes each CheckoutNotification as required.
 void register(java.lang.String notificationType, NotificationHandler notificationHandler)
          Associates the NotificationHandler with the specified notificationType.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CompositeNotificationHandler

public CompositeNotificationHandler()
Method Detail

handle

public void handle(MerchantInfo mi,
                   CheckoutNotification notification)
            throws CheckoutHandlerException
Processes each CheckoutNotification as required.

Specified by:
handle in interface NotificationHandler
Parameters:
mi - The merchant info
notification - The notification message
Throws:
CheckoutHandlerException - if an error occured while processing the notification

register

public void register(java.lang.String notificationType,
                     NotificationHandler notificationHandler)
Associates the NotificationHandler with the specified notificationType. If there is an existing NotificationHandler, it is replaced with the new NotificationHandler.

Parameters:
notificationType - The notification type
notificationHandler - The handler that will handle notifications of the specified notificationType