StructuredPushConsumer.h

Go to the documentation of this file.
00001 /* -*- C++ -*- */
00002 /**
00003  *  @file StructuredPushConsumer.h
00004  *
00005  *  $Id: StructuredPushConsumer.h 81422 2008-04-24 12:33:29Z johnnyw $
00006  *
00007  *  @author Pradeep Gore <pradeep@oomworks.com>
00008  *
00009  *
00010  */
00011 
00012 #ifndef TAO_Notify_STRUCTUREDPUSHCONSUMER_H
00013 #define TAO_Notify_STRUCTUREDPUSHCONSUMER_H
00014 #include /**/ "ace/pre.h"
00015 
00016 #include "orbsvcs/Notify/notify_serv_export.h"
00017 
00018 #if !defined (ACE_LACKS_PRAGMA_ONCE)
00019 # pragma once
00020 #endif /* ACE_LACKS_PRAGMA_ONCE */
00021 
00022 #include "orbsvcs/CosNotifyCommC.h"
00023 #include "orbsvcs/Notify/Consumer.h"
00024 
00025 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
00026 
00027 class TAO_Notify_ProxySupplier;
00028 
00029 /**
00030  * @class TAO_Notify_StructuredPushConsumer
00031  *
00032  * @brief Wrapper for the StructuredPushConsumer that connect to the EventChannel.
00033  *
00034  */
00035 class TAO_Notify_Serv_Export TAO_Notify_StructuredPushConsumer : public TAO_Notify_Consumer
00036 {
00037 public:
00038   /// Constructor
00039   TAO_Notify_StructuredPushConsumer (TAO_Notify_ProxySupplier* proxy);
00040 
00041   /// Init the Consumer
00042   void init (CosNotifyComm::StructuredPushConsumer_ptr push_consumer);
00043 
00044   /// Destructor
00045   virtual ~TAO_Notify_StructuredPushConsumer ();
00046 
00047   /// Push <event> to this consumer.
00048 //  virtual void push_i (const TAO_Notify_Event* event);
00049 
00050   /// Push <event> to this consumer.
00051   virtual void push (const CORBA::Any& event);
00052 
00053   /// Push <event> to this consumer.
00054   virtual void push (const CosNotification::StructuredEvent& event);
00055 
00056   /// Push a batch of events to this consumer.
00057   virtual void push (const CosNotification::EventBatch& event);
00058 
00059   /// Retrieve the ior of this peer
00060   virtual ACE_CString get_ior (void) const;
00061 
00062   /// on reconnect we need to move events from the old consumer
00063   /// to the new one
00064   virtual void reconnect_from_consumer (
00065     TAO_Notify_Consumer* old_consumer);
00066 
00067 
00068 protected:
00069   /// The Consumer
00070   CosNotifyComm::StructuredPushConsumer_var push_consumer_;
00071 
00072 private:
00073   /// Release
00074   virtual void release (void);
00075 };
00076 
00077 TAO_END_VERSIONED_NAMESPACE_DECL
00078 
00079 #include /**/ "ace/post.h"
00080 #endif /* TAO_Notify_STRUCTUREDPUSHCONSUMER_H */

Generated on Tue Feb 2 17:45:29 2010 for TAO_CosNotification by  doxygen 1.4.7