summaryrefslogtreecommitdiff
path: root/indra/llxuixml/llinitparam.h
diff options
context:
space:
mode:
authorRichard Linden <none@none>2012-04-13 11:48:37 -0700
committerRichard Linden <none@none>2012-04-13 11:48:37 -0700
commit61d202a15d70ec56e46bca2edadd49cfd5cbb956 (patch)
tree62e11048d3a1d3cba63c22eb4d5eb510c2e3b7e7 /indra/llxuixml/llinitparam.h
parentfc780921c1e3c411014fe22a31a0fe4d0fd0b2cf (diff)
renamed Lazy to Atomic
Diffstat (limited to 'indra/llxuixml/llinitparam.h')
-rw-r--r--indra/llxuixml/llinitparam.h19
1 files changed, 9 insertions, 10 deletions
diff --git a/indra/llxuixml/llinitparam.h b/indra/llxuixml/llinitparam.h
index 75c09125eb..dcbbf9f0a7 100644
--- a/indra/llxuixml/llinitparam.h
+++ b/indra/llxuixml/llinitparam.h
@@ -395,7 +395,7 @@ namespace LLInitParam
typedef LLInitParam::NOT_BLOCK NOT_BLOCK;
template<typename T>
- class Batch
+ class Atomic
{};
//TODO: implement in terms of owned_ptr
@@ -1916,19 +1916,19 @@ namespace LLInitParam
};
template<typename T, typename BLOCK_IDENTIFIER>
- struct IsBlock<ParamValue<BaseBlock::Batch<T>, TypeValues<BaseBlock::Batch<T> >, typename IsBlock<BaseBlock::Batch<T> >::value_t >, BLOCK_IDENTIFIER>
+ struct IsBlock<ParamValue<BaseBlock::Atomic<T>, TypeValues<BaseBlock::Atomic<T> >, typename IsBlock<BaseBlock::Atomic<T> >::value_t >, BLOCK_IDENTIFIER>
{
typedef typename IsBlock<ParamValue<T, TypeValues<T> > >::value_t value_t;
};
template<typename T, typename BLOCK_T>
- class ParamValue <BaseBlock::Batch<T>,
- TypeValues<BaseBlock::Batch<T> >,
+ class ParamValue <BaseBlock::Atomic<T>,
+ TypeValues<BaseBlock::Atomic<T> >,
BLOCK_T>
: public TypeValues<T>
{
public:
- typedef ParamValue <BaseBlock::Batch<T>, TypeValues<BaseBlock::Batch<T> >, BLOCK_T> self_t;
+ typedef ParamValue <BaseBlock::Atomic<T>, TypeValues<BaseBlock::Atomic<T> >, BLOCK_T> self_t;
typedef ParamValue<T, TypeValues<T> > param_value_t;
typedef const T& value_assignment_t;
typedef T value_t;
@@ -1985,8 +1985,7 @@ namespace LLInitParam
{
if (new_name)
{
- // reset block
- mValue = defaultBatchValue();
+ resetToDefault();
}
return mValue.deserializeBlock(p, name_stack_range, new_name);
}
@@ -2008,7 +2007,7 @@ namespace LLInitParam
{
if (overwrite)
{
- mValue = defaultBatchValue();
+ resetToDefault();
return mValue.mergeBlock(block_data, source, overwrite);
}
return false;
@@ -2028,10 +2027,10 @@ namespace LLInitParam
mutable bool mValidated; // lazy validation flag
private:
- static const T& defaultBatchValue()
+ void resetToDefault()
{
static T default_value;
- return default_value;
+ mValue = default_value;
}
T mValue;