3 //=============================================================================
7 * This file contains the declaration for the ZIOP Stub.
9 * @author Johnny Willemsen <jwillemsen@remedy.nl>
11 //=============================================================================
13 #ifndef TAO_ZIOP_STUB_H_
14 #define TAO_ZIOP_STUB_H_
16 #include /**/ "ace/pre.h"
18 #include "tao/orbconf.h"
20 #include "tao/ZIOP/ziop_export.h"
24 #if !defined (ACE_LACKS_PRAGMA_ONCE)
26 #endif /* ACE_LACKS_PRAGMA_ONCE */
28 #if defined (TAO_HAS_CORBA_MESSAGING) && TAO_HAS_CORBA_MESSAGING != 0
30 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
32 // Forward references.
35 class CompressorIdListPolicy
;
36 class CompressionEnablingPolicy
;
40 * @class TAO_ZIOP_Stub
42 * This class represent a stub with extended functionality, which are needed
45 class TAO_ZIOP_Export TAO_ZIOP_Stub
: public TAO_Stub
48 TAO_ZIOP_Stub (const char *repository_id
,
49 const TAO_MProfile
&profiles
,
50 TAO_ORB_Core
*orb_core
);
52 virtual ~TAO_ZIOP_Stub ();
55 * Returns the effective policy if @a type is a known client-exposed
56 * policy type. Returns the effective override for all other policy
59 CORBA::Policy_ptr
get_policy (CORBA::PolicyType type
);
61 CORBA::Policy_ptr
get_cached_policy (TAO_Cached_Policy_Type type
);
64 /// Helper method used to parse the policies.
65 void parse_policies ();
67 void exposed_compression_enabling_policy (CORBA::Policy_ptr policy
);
69 void exposed_compression_id_list_policy (CORBA::Policy_ptr policy
);
71 CORBA::Policy_ptr
exposed_compression_enabling_policy ();
73 CORBA::Policy_ptr
exposed_compression_id_list_policy ();
75 CORBA::Policy
*effective_compression_enabling_policy ();
76 CORBA::Policy
*effective_compression_id_list_policy ();
78 // The following attribute are used to cache
79 // the different kind of policies and avoid to
80 // parse the MProfile's policy list each time we
81 // are asked about a given policy.
83 CORBA::Policy_var compression_enabling_policy_
;
85 CORBA::Policy_var compression_id_list_policy_
;
87 CORBA::Boolean are_policies_parsed_
;
90 // = Disallow copying and assignment.
91 TAO_ZIOP_Stub (const TAO_ZIOP_Stub
&);
92 TAO_ZIOP_Stub
&operator = (const TAO_ZIOP_Stub
&);
95 TAO_END_VERSIONED_NAMESPACE_DECL
99 #include /**/ "ace/post.h"
101 #endif /* TAO_ZIOP_STUB_FACTORY_H_ */