1 karl 1.10 //%2005////////////////////////////////////////////////////////////////////////
|
2 mike 1.2 //
|
3 karl 1.9 // Copyright (c) 2000, 2001, 2002 BMC Software; Hewlett-Packard Development
4 // Company, L.P.; IBM Corp.; The Open Group; Tivoli Systems.
5 // Copyright (c) 2003 BMC Software; Hewlett-Packard Development Company, L.P.;
|
6 karl 1.6 // IBM Corp.; EMC Corporation, The Open Group.
|
7 karl 1.9 // Copyright (c) 2004 BMC Software; Hewlett-Packard Development Company, L.P.;
8 // IBM Corp.; EMC Corporation; VERITAS Software Corporation; The Open Group.
|
9 karl 1.10 // Copyright (c) 2005 Hewlett-Packard Development Company, L.P.; IBM Corp.;
10 // EMC Corporation; VERITAS Software Corporation; The Open Group.
|
11 mike 1.2 //
12 // Permission is hereby granted, free of charge, to any person obtaining a copy
13 // of this software and associated documentation files (the "Software"), to
14 // deal in the Software without restriction, including without limitation the
15 // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
16 // sell copies of the Software, and to permit persons to whom the Software is
17 // furnished to do so, subject to the following conditions:
|
18 david.dillard 1.12 //
|
19 mike 1.2 // THE ABOVE COPYRIGHT NOTICE AND THIS PERMISSION NOTICE SHALL BE INCLUDED IN
20 // ALL COPIES OR SUBSTANTIAL PORTIONS OF THE SOFTWARE. THE SOFTWARE IS PROVIDED
21 // "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
22 // LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
23 // PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
24 // HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
25 // ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
26 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
27 //
28 //==============================================================================
29 //
30 // Author: Roger Kumpf, Hewlett-Packard Company (roger_kumpf@hp.com)
31 //
|
32 dave.sudlik 1.7 // Modified By: Dave Sudlik, IBM (dsudlik@us.ibm.com), for PEP 164
|
33 aruran.ms 1.11 // Aruran, IBM (ashanmug@in.ibm.com) for Bug# 3614
|
34 david.dillard 1.12 // David Dillard, VERITAS Software Corp.
35 // (david.dillard@veritas.com)
|
36 vijay.eli 1.13 // Vijay Eli, IBM, (vijayeli@in.ibm.com) for Bug# 3613
|
37 aruran.ms 1.14 // Aruran, IBM (ashanmug@in.ibm.com) for Bug# 3613
|
38 mike 1.2 //
39 //%/////////////////////////////////////////////////////////////////////////////
40
41
42 //////////////////////////////////////////////////////////////////////////////
|
43 david.dillard 1.12 //
|
44 mike 1.2 // This file defines the repository property owner class.
45 //
46 //////////////////////////////////////////////////////////////////////////////
47
48 #ifndef Pegasus_RepositoryPropertyOwner_h
49 #define Pegasus_RepositoryPropertyOwner_h
50
51 #include <Pegasus/Config/ConfigPropertyOwner.h>
52
53
54 PEGASUS_NAMESPACE_BEGIN
55
56 ///////////////////////////////////////////////////////////////////
57 // RepositoryPropertyOwner Class
58 ///////////////////////////////////////////////////////////////////
59
|
60 david.dillard 1.12 /**
|
61 mike 1.2 This is Repository property owner class that extends ConfigPropertyOwner
62 class and provides an implementation for repository-related configuration
63 properties.
64 */
65 class PEGASUS_CONFIG_LINKAGE RepositoryPropertyOwner : public ConfigPropertyOwner
66 {
67 public:
68
69 /** Constructors */
70 RepositoryPropertyOwner();
71
72
73 /** Destructor */
74 ~RepositoryPropertyOwner();
75
76 /**
77 Initialize the config properties.
78
79 This method is expected to be called only once at the start of the
80 CIMOM. It initializes the properties with the default values.
81 */
82 mike 1.2 void initialize();
83
84
|
85 david.dillard 1.12 /**
|
86 mike 1.2 Get information about the specified property.
87
88 @param propertyName The name of the property.
89 @param propertyInfo List to store the property info.
90 @exception UnrecognizedConfigProperty if the property is not defined.
91 */
|
92 vijay.eli 1.13 void getPropertyInfo(const String& name, Array<String>& propertyInfo)const;
|
93 mike 1.2
94
|
95 david.dillard 1.12 /**
|
96 mike 1.2 Get default value of the specified property.
97
98 @param name The name of the property.
99 @return string containing the default value of the property specified.
100 @exception UnrecognizedConfigProperty if the property is not defined.
101 */
|
102 vijay.eli 1.13 String getDefaultValue(const String& name)const;
|
103 mike 1.2
104
|
105 david.dillard 1.12 /**
|
106 mike 1.2 Get current value of the specified property.
107
108 @param name The name of the property.
109 @return string containing the currnet value of the property specified.
110 @exception UnrecognizedConfigProperty if the property is not defined.
111 */
|
112 vijay.eli 1.13 String getCurrentValue(const String& name)const;
|
113 mike 1.2
114
|
115 david.dillard 1.12 /**
|
116 mike 1.2 Get planned value of the specified property.
117
118 @param name The name of the property.
119 @return string containing the planned value of the property specified.
120 @exception UnrecognizedConfigProperty if the property is not defined.
121 */
|
122 vijay.eli 1.13 String getPlannedValue(const String& name)const;
|
123 mike 1.2
124
|
125 david.dillard 1.12 /**
|
126 mike 1.2 Init current value of the specified property to the specified value.
127 This method is expected to be called only once at the start of the
128 CIMOM. The property value will be initialized irrespective of whether
129 the property is dynamic or not.
130
131 @param name The name of the property.
|
132 david.dillard 1.12 @param value The current value of the property.
|
133 mike 1.2 @exception UnrecognizedConfigProperty if the property is not defined.
134 @exception InvalidPropertyValue if the property value is not valid.
135 */
136 void initCurrentValue(const String& name, const String& value);
137
138
|
139 david.dillard 1.12 /**
|
140 mike 1.2 Init planned value of the specified property to the specified value.
141 This method is expected to be called only once at the start of the
142 CIMOM. The property value will be initialized irrespective of whether
143 the property is dynamic or not.
144
145 @param name The name of the property.
|
146 david.dillard 1.12 @param value The planned value of the property.
|
147 mike 1.2 @exception UnrecognizedConfigProperty if the property is not defined.
148 @exception InvalidPropertyValue if the property value is not valid.
149 */
|
150 david.dillard 1.12 void initPlannedValue(const String& name, const String& value);
|
151 mike 1.2
152
|
153 david.dillard 1.12 /**
|
154 mike 1.2 Update current value of the specified property to the specified value.
155 The property value will be updated only if the property is dynamically
156 updatable.
157
158 @param name The name of the property.
|
159 david.dillard 1.12 @param value The current value of the property.
|
160 mike 1.2 @exception NonDynamicConfigProperty if the property is not dynamic.
161 @exception InvalidPropertyValue if the property value is not valid.
162 @exception UnrecognizedConfigProperty if the property is not defined.
163 */
164 void updateCurrentValue(const String& name, const String& value);
165 //throw (NonDynamicConfigProperty, InvalidPropertyValue,
166 // UnrecognizedConfigProperty);
167
168
|
169 david.dillard 1.12 /**
|
170 mike 1.2 Update planned value of the specified property to the specified value.
171
172 @param name The name of the property.
|
173 david.dillard 1.12 @param value The planned value of the property.
|
174 mike 1.2 @exception InvalidPropertyValue if the property value is not valid.
175 @exception UnrecognizedConfigProperty if the property is not defined.
176 */
177 void updatePlannedValue(const String& name, const String& value);
178
179
|
180 david.dillard 1.12 /**
|
181 mike 1.2 Checks to see if the given value is valid or not.
182
183 @param name The name of the property.
|
184 david.dillard 1.12 @param value The value of the property to be validated.
|
185 mike 1.2 @return Boolean True if the specified value for the property is valid.
186 @exception UnrecognizedConfigProperty if the property is not defined.
187 */
|
188 vijay.eli 1.13 Boolean isValid(const String& name, const String& value)const;
|
189 mike 1.2
190
|
191 david.dillard 1.12 /**
|
192 mike 1.2 Checks to see if the specified property is dynamic or not.
193
194 @param name The name of the property.
195 @return Boolean True if the specified property is dynamic.
196 @exception UnrecognizedConfigProperty if the property is not defined.
197 */
|
198 vijay.eli 1.13 Boolean isDynamic(const String& name)const;
|
199 mike 1.2
200
201 private:
202
|
203 aruran.ms 1.14 struct ConfigProperty* _lookupConfigProperty(const String& name) const;
|
204 kumpf 1.4
|
205 mike 1.2 /**
206 The repository properties owned by this class
207 */
208 struct ConfigProperty* _repositoryIsDefaultInstanceProvider;
|
209 dave.sudlik 1.7 struct ConfigProperty* _enableBinaryRepository; // PEP 164
|
210 mike 1.2
211 };
212
213 PEGASUS_NAMESPACE_END
214
215 #endif /* Pegasus_RepositoryPropertyOwner_h */
|