DynamicAny improvements (now holds any type out-of-the-box), some refactoring and documentation improvements

This commit is contained in:
Aleksandar Fabijanic
2008-06-30 00:26:54 +00:00
parent e0bb9c162b
commit b1f895eed8
14 changed files with 331 additions and 776 deletions

View File

@@ -252,111 +252,6 @@ public:
return typeid(Data::BLOB);
}
void convert(Int8&) const
{
throw Poco::BadCastException();
}
void convert(Int16&) const
{
throw Poco::BadCastException();
}
void convert(Int32&) const
{
throw Poco::BadCastException();
}
void convert(Int64&) const
{
throw Poco::BadCastException();
}
void convert(UInt8&) const
{
throw Poco::BadCastException();
}
void convert(UInt16&) const
{
throw Poco::BadCastException();
}
void convert(UInt32&) const
{
throw Poco::BadCastException();
}
void convert(UInt64&) const
{
throw Poco::BadCastException();
}
void convert(bool&) const
{
throw Poco::BadCastException();
}
void convert(float&) const
{
throw Poco::BadCastException();
}
void convert(double&) const
{
throw Poco::BadCastException();
}
void convert(char&) const
{
throw Poco::BadCastException();
}
void convert(Poco::Timestamp&) const
{
throw Poco::BadCastException();
}
void convert(Poco::DateTime&) const
{
throw Poco::BadCastException();
}
void convert(Poco::LocalDateTime&) const
{
throw Poco::BadCastException();
}
bool isArray() const
{
return false;
}
virtual bool isStruct() const
{
return false;
}
bool isInteger() const
{
return false;
}
bool isSigned() const
{
return false;
}
bool isNumeric() const
{
return false;
}
bool isString() const
{
return false;
}
void convert(std::string& val) const
{
val.assign(_val.begin(), _val.end());

View File

@@ -182,66 +182,6 @@ public:
return typeid(Data::Date);
}
void convert(Int8&) const
{
throw Poco::BadCastException();
}
void convert(Int16&) const
{
throw Poco::BadCastException();
}
void convert(Int32&) const
{
throw Poco::BadCastException();
}
void convert(Int64&) const
{
throw Poco::BadCastException();
}
void convert(UInt8&) const
{
throw Poco::BadCastException();
}
void convert(UInt16&) const
{
throw Poco::BadCastException();
}
void convert(UInt32&) const
{
throw Poco::BadCastException();
}
void convert(UInt64&) const
{
throw Poco::BadCastException();
}
void convert(bool&) const
{
throw Poco::BadCastException();
}
void convert(float&) const
{
throw Poco::BadCastException();
}
void convert(double&) const
{
throw Poco::BadCastException();
}
void convert(char&) const
{
throw Poco::BadCastException();
}
void convert(Poco::Timestamp& val) const
{
DateTime dt;
@@ -259,36 +199,6 @@ public:
val.assign(_val.year(), _val.month(), _val.day());
}
bool isArray() const
{
return false;
}
virtual bool isStruct() const
{
return false;
}
bool isInteger() const
{
return false;
}
bool isSigned() const
{
return false;
}
bool isNumeric() const
{
return false;
}
bool isString() const
{
return false;
}
void convert(std::string& val) const
{
DateTime dt(_val.year(), _val.month(), _val.day());

View File

@@ -182,66 +182,6 @@ public:
return typeid(Data::Time);
}
void convert(Int8&) const
{
throw Poco::BadCastException();
}
void convert(Int16&) const
{
throw Poco::BadCastException();
}
void convert(Int32&) const
{
throw Poco::BadCastException();
}
void convert(Int64&) const
{
throw Poco::BadCastException();
}
void convert(UInt8&) const
{
throw Poco::BadCastException();
}
void convert(UInt16&) const
{
throw Poco::BadCastException();
}
void convert(UInt32&) const
{
throw Poco::BadCastException();
}
void convert(UInt64&) const
{
throw Poco::BadCastException();
}
void convert(bool&) const
{
throw Poco::BadCastException();
}
void convert(float&) const
{
throw Poco::BadCastException();
}
void convert(double&) const
{
throw Poco::BadCastException();
}
void convert(char&) const
{
throw Poco::BadCastException();
}
void convert(Poco::Timestamp& val) const
{
Poco::DateTime dt;
@@ -263,36 +203,6 @@ public:
val = ldt;
}
bool isArray() const
{
return false;
}
virtual bool isStruct() const
{
return false;
}
bool isInteger() const
{
return false;
}
bool isSigned() const
{
return false;
}
bool isNumeric() const
{
return false;
}
bool isString() const
{
return false;
}
void convert(std::string& val) const
{
DateTime dt(0, 1, 1, _val.hour(), _val.minute(), _val.second());