1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
|
// $Id$
#include "EC_SupplierFiltering.h"
#include "EC_Event_Channel.h"
#include "EC_ConsumerAdmin.h"
#include "EC_ProxySupplier.h"
#include "EC_QOS_Info.h"
#if ! defined (__ACE_INLINE__)
#include "EC_SupplierFiltering.i"
#endif /* __ACE_INLINE__ */
ACE_RCSID(Event, EC_SupplierFiltering, "$Id$")
TAO_EC_SupplierFiltering::~TAO_EC_SupplierFiltering (void)
{
}
// ****************************************************************
TAO_EC_Null_SupplierFiltering::
TAO_EC_Null_SupplierFiltering (TAO_EC_Event_Channel* ec)
: event_channel_ (ec)
{
}
void
TAO_EC_Null_SupplierFiltering::bind (TAO_EC_ProxyPushConsumer*)
{
}
void
TAO_EC_Null_SupplierFiltering::unbind (TAO_EC_ProxyPushConsumer*)
{
}
void
TAO_EC_Null_SupplierFiltering::connected (TAO_EC_ProxyPushSupplier*,
CORBA::Environment &)
{
}
void
TAO_EC_Null_SupplierFiltering::disconnected (TAO_EC_ProxyPushSupplier*,
CORBA::Environment &)
{
}
void
TAO_EC_Null_SupplierFiltering::push (const RtecEventComm::EventSet& event,
CORBA::Environment &ACE_TRY_ENV)
{
TAO_EC_ConsumerAdmin* consumer_admin =
this->event_channel_->consumer_admin ();
ACE_GUARD_THROW (TAO_EC_ConsumerAdmin::Busy_Lock,
ace_mon, consumer_admin->busy_lock (),
RtecEventChannelAdmin::EventChannel::SYNCHRONIZATION_ERROR ());
TAO_EC_ConsumerAdmin::SupplierSetIterator end =
consumer_admin->end ();
for (CORBA::ULong j = 0; j < event.length (); ++j)
{
const RtecEventComm::Event& e = event[j];
RtecEventComm::Event* buffer =
ACE_const_cast(RtecEventComm::Event*, &e);
RtecEventComm::EventSet single_event (1, 1, buffer, 0);
for (TAO_EC_ConsumerAdmin::SupplierSetIterator i =
consumer_admin->begin ();
i != end;
++i)
{
TAO_EC_QOS_Info qos_info;
(*i)->filter (single_event, qos_info, ACE_TRY_ENV);
ACE_CHECK;
}
}
}
|