summaryrefslogtreecommitdiff
path: root/ace/RMCast/RMCast_Reliable_Factory.h
blob: e41c7fd9e74e980bc65e322ee3348d61a112e355 (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
/* -*- C++ -*- */
// $Id$

// ============================================================================
//
// = LIBRARY
//    ace
//
// = FILENAME
//    RMCast_Reliable_Factory.h
//
// = AUTHOR
//    Carlos O'Ryan <coryan@uci.edu>
//
// ============================================================================

#ifndef ACE_RMCAST_RELIABLE_FACTORY_H
#define ACE_RMCAST_RELIABLE_FACTORY_H
#include "ace/pre.h"

#include "RMCast_Module_Factory.h"

#if !defined (ACE_LACKS_PRAGMA_ONCE)
# pragma once
#endif /* ACE_LACKS_PRAGMA_ONCE */

/// Implement an ACE_RMCast_Module_Factory that "creates" a single
/// object.
/**
 * Many applications (and even some internal components), will use a
 * single ACE_RMCast_Module to process all the events, for example, a
 * receiver may decide to use the same ACE_RMCast_Module to process
 * all incoming events, instead of using one per remote sender.
 */
class ACE_RMCast_Export ACE_RMCast_Reliable_Factory : public ACE_RMCast_Module_Factory
{
public:
  /// Constructor
  /**
   * The create() method will return always \param reliable.
   */
  ACE_RMCast_Reliable_Factory (ACE_RMCast_Module_Factory *factory);

  //! Destructor
  virtual ~ACE_RMCast_Reliable_Factory (void);

  virtual ACE_RMCast_Module *create (void);
  virtual void destroy (ACE_RMCast_Module *);

private:
  /// Delegate on another factory to create the user module
  ACE_RMCast_Module_Factory *factory_;
};

#if defined (__ACE_INLINE__)
#include "RMCast_Reliable_Factory.i"
#endif /* __ACE_INLINE__ */

#include "ace/post.h"
#endif /* ACE_RMCAST_RELIABLE_FACTORY_H */