version 1.29, 2009/06/11 07:28:57
|
version 1.29.6.1, 2013/06/03 22:35:51
|
|
|
#include <Pegasus/Common/FileSystem.h> | #include <Pegasus/Common/FileSystem.h> |
#include <Pegasus/Config/ConfigManager.h> | #include <Pegasus/Config/ConfigManager.h> |
#include "ProviderDirPropertyOwner.h" | #include "ProviderDirPropertyOwner.h" |
|
#include "ConfigExceptions.h" |
| |
PEGASUS_NAMESPACE_BEGIN | PEGASUS_NAMESPACE_BEGIN |
| |
|
|
const String& name, | const String& name, |
Array<String>& propertyInfo) const | Array<String>& propertyInfo) const |
{ | { |
propertyInfo.clear(); |
|
struct ConfigProperty * configProperty = _lookupConfigProperty(name); | struct ConfigProperty * configProperty = _lookupConfigProperty(name); |
| |
propertyInfo.append(configProperty->propertyName); |
buildPropertyInfo(name, configProperty, propertyInfo); |
propertyInfo.append(configProperty->defaultValue); |
|
propertyInfo.append(configProperty->currentValue); |
|
propertyInfo.append(configProperty->plannedValue); |
|
if (configProperty->dynamic) |
|
{ |
|
propertyInfo.append(STRING_TRUE); |
|
} |
|
else |
|
{ |
|
propertyInfo.append(STRING_FALSE); |
|
} |
|
if (configProperty->externallyVisible) |
|
{ |
|
propertyInfo.append(STRING_TRUE); |
|
} |
|
else |
|
{ |
|
propertyInfo.append(STRING_FALSE); |
|
} |
|
} | } |
| |
|
|
/** | /** |
Get default value of the specified property. | Get default value of the specified property. |
*/ | */ |
|
|
const String& userName, | const String& userName, |
Uint32 timeoutSeconds) | Uint32 timeoutSeconds) |
{ | { |
|
struct ConfigProperty * configProperty = _lookupConfigProperty(name); |
|
|
// | // |
// make sure the property is dynamic before updating the value. | // make sure the property is dynamic before updating the value. |
// | // |
if (!isDynamic(name)) |
if (configProperty->dynamic != IS_DYNAMIC) |
{ | { |
throw NonDynamicConfigProperty(name); | throw NonDynamicConfigProperty(name); |
} | } |
initCurrentValue(name, value); |
|
|
AutoMutex lock(_providerDirMutex); |
|
configProperty->currentValue = value; |
} | } |
| |
| |