mirror of
https://github.com/pocoproject/poco.git
synced 2025-10-21 15:51:43 +02:00
few cosmetic changes
This commit is contained in:
@@ -134,11 +134,8 @@ public:
|
|||||||
return value;
|
return value;
|
||||||
}
|
}
|
||||||
|
|
||||||
void add(const Dynamic::Var& value)
|
void add(const Dynamic::Var& value);
|
||||||
/// Add the given value to the array
|
/// Add the given value to the array
|
||||||
{
|
|
||||||
_values.push_back(value);
|
|
||||||
}
|
|
||||||
|
|
||||||
void stringify(std::ostream& out, unsigned int indent) const;
|
void stringify(std::ostream& out, unsigned int indent) const;
|
||||||
/// Prints the array to out. When indent is 0, the array
|
/// Prints the array to out. When indent is 0, the array
|
||||||
@@ -178,14 +175,9 @@ inline bool Array::isArray(unsigned int index) const
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
inline bool Array::isNull(unsigned int index) const
|
inline void Array::add(const Dynamic::Var& value)
|
||||||
{
|
{
|
||||||
if ( index < _values.size() )
|
_values.push_back(value);
|
||||||
{
|
|
||||||
Dynamic::Var value = _values[index];
|
|
||||||
return value.isEmpty();
|
|
||||||
}
|
|
||||||
return true;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@@ -118,8 +118,7 @@ public:
|
|||||||
{
|
{
|
||||||
T value = def;
|
T value = def;
|
||||||
ValueMap::const_iterator it = _values.find(key);
|
ValueMap::const_iterator it = _values.find(key);
|
||||||
if ( it != _values.end()
|
if (it != _values.end() && ! it->second.isEmpty() )
|
||||||
&& ! it->second.isEmpty() )
|
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
@@ -102,6 +102,17 @@ Object::Ptr Array::getObject(unsigned int index) const
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
bool Array::isNull(unsigned int index) const
|
||||||
|
{
|
||||||
|
if ( index < _values.size() )
|
||||||
|
{
|
||||||
|
Dynamic::Var value = _values[index];
|
||||||
|
return value.isEmpty();
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
bool Array::isObject(unsigned int index) const
|
bool Array::isObject(unsigned int index) const
|
||||||
{
|
{
|
||||||
Var value = get(index);
|
Var value = get(index);
|
||||||
|
Reference in New Issue
Block a user