Revert "Minor modernization of DynamicAny code"
[ACE_TAO.git] / TAO / tao / Collocation_Strategy.h
blob8bf077ebe03003b45818fdef3b9a75b2336f6ecf
1 // -*- C++ -*-
3 //=============================================================================
4 /**
5 * @file Collocation_Strategy.h
7 * @author DOC Group - Wash U and UCI
8 */
9 //=============================================================================
11 #ifndef TAO_COLLOCATION_STRATEGY_H
12 #define TAO_COLLOCATION_STRATEGY_H
14 #include /**/ "ace/pre.h"
15 #include "tao/orbconf.h"
16 #include /**/ "tao/Versioned_Namespace.h"
18 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
20 /// Define symbolic names for the ORB collocation strategies as used at runtime.
21 namespace TAO
23 enum Collocation_Strategy
25 /// i.e no collocation.
26 TAO_CS_REMOTE_STRATEGY,
28 /// Calls to the collocated object are forwarded by the POA.
29 TAO_CS_THRU_POA_STRATEGY,
31 /// Calls to the collocated object are made directly to its
32 /// servant.
33 TAO_CS_DIRECT_STRATEGY,
35 /// This value should always be the last value in the enumeration.
36 /// It provides the count for the number of collocation
37 /// strategies.
38 TAO_CS_LAST
41 inline const char * translate_collocation_strategy (Collocation_Strategy cs)
43 #define TAO_CS(X) case X: return #X
44 switch (cs)
46 TAO_CS (TAO_CS_REMOTE_STRATEGY);
47 TAO_CS (TAO_CS_THRU_POA_STRATEGY);
48 TAO_CS (TAO_CS_DIRECT_STRATEGY);
49 TAO_CS (TAO_CS_LAST);
51 return "***Unknown enum value, update TAO::translate_collocation_strategy()";
52 #undef TAO_CS
55 /// No collocation possible
56 int const TAO_CO_NONE = 0x00;
58 /// Through POA collocation is possible
59 int const TAO_CO_THRU_POA_STRATEGY = 0x01;
61 /// Direct collocation is possible
62 int const TAO_CO_DIRECT_STRATEGY = 0x02;
65 TAO_END_VERSIONED_NAMESPACE_DECL
67 #include /**/ "ace/post.h"
69 #endif /* TAO_COLLOCATION_STRATEGY_H */