blob: a756f101782612b0f6aeed4bf7b55079ee8cb013 (
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
105
106
107
108
109
110
111
112
113
114
|
// -*- C++ -*-
//=============================================================================
/**
* @file POA_Cached_Policies.h
*
* $Id$
*
* POA
*
* @author Irfan Pyarali
*/
//=============================================================================
#ifndef TAO_POA_CACHED_POLICIES_H
#define TAO_POA_CACHED_POLICIES_H
#include /**/ "ace/pre.h"
#include "tao/PortableServer/portableserver_export.h"
#if !defined (ACE_LACKS_PRAGMA_ONCE)
# pragma once
#endif /* ACE_LACKS_PRAGMA_ONCE */
#include "tao/PortableServer/ThreadPolicyC.h"
#include "tao/PortableServer/LifespanPolicyC.h"
#include "tao/PortableServer/IdUniquenessPolicyC.h"
#include "tao/PortableServer/IdAssignmentPolicyC.h"
#include "tao/PortableServer/ImplicitActivationPolicyC.h"
#include "tao/PortableServer/ServantRetentionPolicyC.h"
#include "tao/PortableServer/RequestProcessingPolicyC.h"
TAO_BEGIN_VERSIONED_NAMESPACE_DECL
// Forward references.
class TAO_POA_Policy_Set;
namespace TAO
{
namespace Portable_Server
{
class TAO_PortableServer_Export Cached_Policies
{
public:
enum PriorityModel
{
CLIENT_PROPAGATED,
SERVER_DECLARED,
NOT_SPECIFIED
};
Cached_Policies ();
~Cached_Policies (void);
/// Update the cached policy values.
void update (TAO_POA_Policy_Set &policy_set
ACE_ENV_ARG_DECL);
/**
* @name Accessor methods to cached values.
*/
//@{
::PortableServer::ThreadPolicyValue thread (void) const;
::PortableServer::LifespanPolicyValue lifespan (void) const;
::PortableServer::IdUniquenessPolicyValue id_uniqueness (void) const;
::PortableServer::IdAssignmentPolicyValue id_assignment (void) const;
::PortableServer::ImplicitActivationPolicyValue implicit_activation (void) const;
::PortableServer::ServantRetentionPolicyValue servant_retention (void) const;
::PortableServer::RequestProcessingPolicyValue request_processing (void) const;
PriorityModel priority_model (void) const;
CORBA::Short server_priority (void) const;
void priority_model (PriorityModel priority_model);
void server_priority (CORBA::Short priority);
void implicit_activation (::PortableServer::ImplicitActivationPolicyValue value);
//@}
protected:
/// Helper method to update a particular policy.
void update_policy (const CORBA::Policy_ptr policy
ACE_ENV_ARG_DECL);
::PortableServer::ThreadPolicyValue thread_;
::PortableServer::LifespanPolicyValue lifespan_;
::PortableServer::IdUniquenessPolicyValue id_uniqueness_;
::PortableServer::IdAssignmentPolicyValue id_assignment_;
::PortableServer::ImplicitActivationPolicyValue implicit_activation_;
::PortableServer::ServantRetentionPolicyValue servant_retention_;
::PortableServer::RequestProcessingPolicyValue request_processing_;
PriorityModel priority_model_;
CORBA::Short server_priority_;
};
}
}
TAO_END_VERSIONED_NAMESPACE_DECL
#if defined (__ACE_INLINE__)
# include "tao/PortableServer/POA_Cached_Policies.i"
#endif /* __ACE_INLINE__ */
#include /**/ "ace/post.h"
#endif /* TAO_POA_CACHED_POLICIES_H */
|