summaryrefslogtreecommitdiff
path: root/ace/RMCast/RMCast_Reassembly.h
blob: 0bf0c3a61ee93d920b558d744da582a405c6a87b (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
// $Id$

// ============================================================================
//
// = DESCRIPTION
//   The reassembly task for the reliable multicast library
//
// = AUTHOR
//    Carlos O'Ryan <coryan@uci.edu>
//
// ============================================================================

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

#include "RMCast_Module.h"
#include "ace/Hash_Map_Manager.h"
#include "ace/Synch.h"

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

class ACE_RMCast_Partial_Message;

class ACE_RMCast_Export ACE_RMCast_Reassembly : public ACE_RMCast_Module
{
public:
  ACE_RMCast_Reassembly (void);
  // Constructor

  virtual ~ACE_RMCast_Reassembly (void);
  // Destructor

  // = The ACE_RMCast_Module methods
  virtual int data (ACE_RMCast::Data &data);

private:
  ACE_SYNCH_MUTEX mutex_;
  typedef
      ACE_Hash_Map_Manager<ACE_UINT32,ACE_RMCast_Partial_Message*,ACE_Null_Mutex>
      Message_Map;
  typedef
      ACE_Hash_Map_Iterator<ACE_UINT32,ACE_RMCast_Partial_Message*,ACE_Null_Mutex>
      Message_Map_Iterator;

  Message_Map messages_;
  // The array of partially received messages
};

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

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