blob: 44f2719c6d26f9cea1a1544f4952421b0d648584 (
plain)
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
|
/* -*- C++ -*- */
// $Id$
//
// ============================================================================
//
// = LIBRARY
// ORBSVCS Cos Event Channel
//
// = FILENAME
// CEC_Pulling_Strategy
//
// = AUTHOR
// Carlos O'Ryan (coryan@cs.wustl.edu)
//
// = CREDITS
//
// ============================================================================
#ifndef TAO_CEC_PULLING_STRATEGY_H
#define TAO_CEC_PULLING_STRATEGY_H
#include "ace/pre.h"
#include "orbsvcs/CosEvent/event_export.h"
#if !defined (ACE_LACKS_PRAGMA_ONCE)
# pragma once
#endif /* ACE_LACKS_PRAGMA_ONCE */
class TAO_Event_Export TAO_CEC_Pulling_Strategy
{
// = TITLE
// Define the interface for the pulling strategies.
//
// = DESCRIPTION
// The EC may be configured with different pulling strategies,
// for instance, it can use a pool of threads to dispatch the
// events, or a set of queues with threads at different priorities
// for each queue or can simply push the event to the consumer in
// FIFO order.
//
public:
virtual ~TAO_CEC_Pulling_Strategy (void);
// destructor...
virtual void activate (void) = 0;
// Initialize all the data structures, activate any internal threads,
// etc.
virtual void shutdown (void) = 0;
// Deactivate any internal threads and cleanup internal data
// structures, it should only return once the threads have finished
// their jobs.
#if 0
virtual void connected (TAO_CEC_ProxyPullConsumer *,
CORBA::Environment &) = 0;
virtual void reconnected (TAO_CEC_ProxyPullConsumer *,
CORBA::Environment &) = 0;
virtual void diconnected (TAO_CEC_ProxyPullConsumer *,
CORBA::Environment &) = 0;
// Some strategies may want to keep track of connected consumers.
#endif /* 0 */
};
#if defined (__ACE_INLINE__)
#include "CEC_Pulling_Strategy.i"
#endif /* __ACE_INLINE__ */
#include "ace/post.h"
#endif /* TAO_CEC_PULLING_STRATEGY_H */
|