mirror of
https://github.com/pocoproject/poco.git
synced 2025-10-15 07:14:46 +02:00
Dynamic::Var SOO
Dynamic::Var small object optimization and some refactoring
This commit is contained in:
@@ -279,22 +279,22 @@ public:
|
||||
|
||||
void convert(DateTime& /*val*/) const
|
||||
{
|
||||
throw BadCastException();
|
||||
throw BadCastException("Cannot convert Array to DateTime");
|
||||
}
|
||||
|
||||
void convert(LocalDateTime& /*ldt*/) const
|
||||
{
|
||||
throw BadCastException();
|
||||
throw BadCastException("Cannot convert Array to LocalDateTime");
|
||||
}
|
||||
|
||||
void convert(Timestamp& /*ts*/) const
|
||||
{
|
||||
throw BadCastException();
|
||||
throw BadCastException("Cannot convert Array to Timestamp");
|
||||
}
|
||||
|
||||
VarHolder* clone() const
|
||||
VarHolder* clone(Placeholder<VarHolder>* pVarHolder = 0) const
|
||||
{
|
||||
return new VarHolderImpl(_val);
|
||||
return cloneHolder(pVarHolder, _val);
|
||||
}
|
||||
|
||||
const JSON::Array::Ptr& value() const
|
||||
|
@@ -291,21 +291,24 @@ public:
|
||||
void convert(DateTime& /*val*/) const
|
||||
{
|
||||
//TODO: val = _val;
|
||||
throw NotImplementedException("Conversion not implemented: JSON:Object => DateTime");
|
||||
}
|
||||
|
||||
void convert(LocalDateTime& /*ldt*/) const
|
||||
{
|
||||
//TODO: ldt = _val.timestamp();
|
||||
throw NotImplementedException("Conversion not implemented: JSON:Object => LocalDateTime");
|
||||
}
|
||||
|
||||
void convert(Timestamp& /*ts*/) const
|
||||
{
|
||||
//TODO: ts = _val.timestamp();
|
||||
throw NotImplementedException("Conversion not implemented: JSON:Object => Timestamp");
|
||||
}
|
||||
|
||||
VarHolderImpl* clone() const
|
||||
VarHolder* clone(Placeholder<VarHolder>* pVarHolder = 0) const
|
||||
{
|
||||
return new VarHolderImpl(_val);
|
||||
return cloneHolder(pVarHolder, _val);
|
||||
}
|
||||
|
||||
const JSON::Object::Ptr& value() const
|
||||
|
Reference in New Issue
Block a user