blob: 3fa0caa8170b95d72c2163ec7ab1e625f4c92d38 (
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
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
|
// -*- C++ -*-
// ===================================================================
/**
* @file ORBInitializer_Registry_Adapter.h
*
* $Id$
*
* @author Johnny Willemsen <jwillemsen@remedy.nl>
*/
// ===================================================================
#ifndef TAO_ORB_INITIALIZER_REGISTRY_ADAPTER_H
#define TAO_ORB_INITIALIZER_REGISTRY_ADAPTER_H
#include /**/ "ace/pre.h"
#include /**/ "tao/TAO_Export.h"
#if !defined (ACE_LACKS_PRAGMA_ONCE)
# pragma once
#endif /* ACE_LACKS_PRAGMA_ONCE */
#include "tao/Basic_Types.h"
#include "tao/SystemException.h"
#include "ace/Service_Object.h"
#include "ace/CORBA_macros.h"
TAO_BEGIN_VERSIONED_NAMESPACE_DECL
class TAO_ORB_Core;
namespace PortableInterceptor
{
class ORBInitializer;
typedef ORBInitializer *ORBInitializer_ptr;
typedef CORBA::ULong SlotId;
}
namespace TAO
{
/**
* @class ORBInitializer_Registry_Adapter
*
* Class that offers an interface to the ORB to load and manipulate
* ORBInitializer_Registry
*/
class TAO_Export ORBInitializer_Registry_Adapter
: public ACE_Service_Object
{
public:
virtual ~ORBInitializer_Registry_Adapter (void);
/// Register an ORBInitializer with the underlying ORBInitializer
/// array.
virtual void register_orb_initializer (
PortableInterceptor::ORBInitializer_ptr init
ACE_ENV_ARG_DECL) = 0;
/**
* Begin initialization of all registered ORBInitializers before
* the ORB itself is initialized.
* @return Returns the number of initializers called by pre_init, exactly
* the same number must be called by post_init. During pre_init new
* initializers can be registered, these must not be called during
* post_init
*/
virtual size_t pre_init (
TAO_ORB_Core *orb_core,
int argc,
char *argv[],
PortableInterceptor::SlotId &slotid
ACE_ENV_ARG_DECL) = 0;
/**
* Complete initialization of all registered ORBInitializers after
* the ORB has been initialized. Returns the number of slots
* allocated.
* @param pre_init_count The number of ORBInitializers we must
* call post_init on. There can be more in the registry when during
* pre_init new interceptors are regisered
* @param orb_core The ORB Core
* @param argc Number of arguments
* @param argv Argv array
* @param slotid The slot id
* @param picurrent PI Current, if this is not null, the concrete
* implementation will update the slot id
*/
virtual void post_init (
size_t pre_init_count,
TAO_ORB_Core *orb_core,
int argc,
char *argv[],
PortableInterceptor::SlotId slotid
ACE_ENV_ARG_DECL) = 0;
};
}
TAO_END_VERSIONED_NAMESPACE_DECL
#include /**/ "ace/post.h"
#endif /* TAO_ORB_INITIALIZER_REGISTRY_ADAPTER_H */
|