step, date, time

This commit is contained in:
Aleksandar Fabijanic
2007-11-10 23:21:28 +00:00
parent 95c5230389
commit fca08a18df
63 changed files with 2161 additions and 96 deletions

View File

@@ -36,6 +36,8 @@
#include "Poco/Data/SQLite/Extractor.h"
#include "Poco/Data/SQLite/Utility.h"
#include "Poco/Data/Date.h"
#include "Poco/Data/Time.h"
#include "Poco/Data/BLOB.h"
#include "Poco/Data/DataException.h"
#include "Poco/DateTimeParser.h"
@@ -205,6 +207,28 @@ bool Extractor::extract(std::size_t pos, char& val)
}
bool Extractor::extract(std::size_t pos, Date& val)
{
std::string str;
extract(pos, str);
int tzd;
DateTime dt = DateTimeParser::parse(Utility::SQLITE_DATE_FORMAT, str, tzd);
val = dt;
return true;
}
bool Extractor::extract(std::size_t pos, Time& val)
{
std::string str;
extract(pos, str);
int tzd;
DateTime dt = DateTimeParser::parse(Utility::SQLITE_TIME_FORMAT, str, tzd);
val = dt;
return true;
}
bool Extractor::extract(std::size_t pos, DateTime& val)
{
std::string dt;