summaryrefslogtreecommitdiff
path: root/TAO/orbsvcs/orbsvcs/Event/EC_ConsumerAdmin.h
diff options
context:
space:
mode:
Diffstat (limited to 'TAO/orbsvcs/orbsvcs/Event/EC_ConsumerAdmin.h')
-rw-r--r--TAO/orbsvcs/orbsvcs/Event/EC_ConsumerAdmin.h49
1 files changed, 22 insertions, 27 deletions
diff --git a/TAO/orbsvcs/orbsvcs/Event/EC_ConsumerAdmin.h b/TAO/orbsvcs/orbsvcs/Event/EC_ConsumerAdmin.h
index 4dee0091898..210698e92bf 100644
--- a/TAO/orbsvcs/orbsvcs/Event/EC_ConsumerAdmin.h
+++ b/TAO/orbsvcs/orbsvcs/Event/EC_ConsumerAdmin.h
@@ -12,6 +12,11 @@
// = AUTHOR
// Carlos O'Ryan (coryan@cs.wustl.edu)
//
+// = DESCRIPTION
+// Implement the RtecEventChannelAdmin::ConsumerAdmin interface.
+// This class is an Abstract Factory for the
+// TAO_EC_ProxyPushSupplier.
+//
// = CREDITS
// Based on previous work by Tim Harrison (harrison@cs.wustl.edu)
// and other members of the DOC group.
@@ -19,37 +24,35 @@
// http://www.cs.wustl.edu/~schmidt/oopsla.ps.gz
// http://www.cs.wustl.edu/~schmidt/JSAC-98.ps.gz
//
+//
// ============================================================================
#ifndef TAO_EC_CONSUMERADMIN_H
#define TAO_EC_CONSUMERADMIN_H
#include "ace/Containers.h"
+#include "orbsvcs/RtecEventChannelAdminS.h"
+#include "orbsvcs/Event/EC_Filter.h"
#if !defined (ACE_LACKS_PRAGMA_ONCE)
# pragma once
#endif /* ACE_LACKS_PRAGMA_ONCE */
-#include "orbsvcs/RtecEventChannelAdminS.h"
-#include "EC_ProxyPushSupplier_Set.h"
-
class TAO_EC_Event_Channel;
class TAO_EC_ProxyPushSupplier;
class TAO_EC_ProxyPushConsumer;
-class TAO_ORBSVCS_Export TAO_EC_ConsumerAdmin : public POA_RtecEventChannelAdmin::ConsumerAdmin
+class TAO_EC_ConsumerAdmin : public POA_RtecEventChannelAdmin::ConsumerAdmin
{
// = TITLE
- // ConsumerAdmin
+ // ProxyPushSupplier
//
// = DESCRIPTION
// Implements the ConsumerAdmin interface, i.e. the factory for
// ProxyPushSupplier objects.
//
// = MEMORY MANAGMENT
- // It does not assume ownership of the TAO_EC_Event_Channel
- // object; but it *does* assume ownership of the
- // TAO_EC_ProxyPushSupplier_Set object.
+ // It does not assume ownership of the TAO_EC_Event_Channel object
//
// = LOCKING
// No provisions for locking, access must be serialized
@@ -58,24 +61,24 @@ class TAO_ORBSVCS_Export TAO_EC_ConsumerAdmin : public POA_RtecEventChannelAdmin
// = TODO
//
public:
- TAO_EC_ConsumerAdmin (TAO_EC_Event_Channel* event_channel,
- TAO_EC_ProxyPushSupplier_Set* supplier_set = 0);
- // constructor. If <supplier_set> is nil then it builds one using
- // the <event_channel> argument.
- // In any case it assumes ownership.
+ TAO_EC_ConsumerAdmin (TAO_EC_Event_Channel* event_channel);
+ // constructor...
virtual ~TAO_EC_ConsumerAdmin (void);
// destructor...
- typedef TAO_EC_ProxyPushSupplier_Set::SupplierSet SupplierSet;
- typedef TAO_EC_ProxyPushSupplier_Set::SupplierSetIterator SupplierSetIterator;
+ typedef ACE_Unbounded_Set<TAO_EC_ProxyPushSupplier*> SupplierSet;
+ typedef ACE_Unbounded_Set_Iterator<TAO_EC_ProxyPushSupplier*> SupplierSetIterator;
SupplierSetIterator begin (void);
SupplierSetIterator end (void);
// Iterators over the set of ProxyPushSuppliers
- typedef TAO_EC_ProxyPushSupplier_Set::Busy_Lock Busy_Lock;
- Busy_Lock& busy_lock (void);
+ void set_default_POA (PortableServer::POA_ptr poa);
+ // Set this servant's default POA
+
+ virtual PortableServer::POA_ptr _default_POA (CORBA::Environment& env);
+ // Override the ServantBase method.
virtual void connected (TAO_EC_ProxyPushConsumer*,
CORBA::Environment&);
@@ -91,26 +94,18 @@ public:
// Used to inform the EC that a Supplier has connected or
// disconnected from it.
- virtual void shutdown (CORBA::Environment&);
- // The event channel is shutting down, inform all the consumers of
- // this
-
// = The RtecEventChannelAdmin::ConsumerAdmin methods...
virtual RtecEventChannelAdmin::ProxyPushSupplier_ptr
obtain_push_supplier (CORBA::Environment &);
- // = The PortableServer::ServantBase methods
- virtual PortableServer::POA_ptr _default_POA (CORBA::Environment& env);
-
private:
TAO_EC_Event_Channel *event_channel_;
// The Event Channel we belong to
- TAO_EC_ProxyPushSupplier_Set* supplier_set_;
- // The implementation for the supplier set container.
-
PortableServer::POA_var default_POA_;
// Store the default POA.
+
+ SupplierSet all_suppliers_;
};
#if defined (__ACE_INLINE__)