[SF 2272430] BLOB and CLOB

Renamed:
(Abstract)Preparation => (Abstract)Preparator
(Abstract)Prepare => (Abstract)Preparation
This commit is contained in:
Aleksandar Fabijanic
2008-11-24 00:38:23 +00:00
parent 161e49a6d4
commit a42e8d919b
75 changed files with 2616 additions and 2832 deletions

View File

@@ -37,7 +37,7 @@
#include "Poco/Data/AbstractBinder.h"
#include "Poco/Data/Date.h"
#include "Poco/Data/Time.h"
#include "Poco/Data/BLOB.h"
#include "Poco/Data/LOB.h"
#include "Poco/Data/DataException.h"
#include "Poco/DateTime.h"
#include "Poco/Any.h"
@@ -330,6 +330,24 @@ void AbstractBinder::bind(std::size_t pos, const std::list<BLOB>& val, Direction
}
void AbstractBinder::bind(std::size_t pos, const std::vector<CLOB>& val, Direction dir)
{
throw NotImplementedException("std::vector binder must be implemented.");
}
void AbstractBinder::bind(std::size_t pos, const std::deque<CLOB>& val, Direction dir)
{
throw NotImplementedException("std::deque binder must be implemented.");
}
void AbstractBinder::bind(std::size_t pos, const std::list<CLOB>& val, Direction dir)
{
throw NotImplementedException("std::list binder must be implemented.");
}
void AbstractBinder::bind(std::size_t pos, const std::vector<DateTime>& val, Direction dir)
{
throw NotImplementedException("std::vector binder must be implemented.");

View File

@@ -324,6 +324,24 @@ bool AbstractExtractor::extract(std::size_t pos, std::list<BLOB>& val)
}
bool AbstractExtractor::extract(std::size_t pos, std::vector<CLOB>& val)
{
throw NotImplementedException("std::vector extractor must be implemented.");
}
bool AbstractExtractor::extract(std::size_t pos, std::deque<CLOB>& val)
{
throw NotImplementedException("std::deque extractor must be implemented.");
}
bool AbstractExtractor::extract(std::size_t pos, std::list<CLOB>& val)
{
throw NotImplementedException("std::list extractor must be implemented.");
}
bool AbstractExtractor::extract(std::size_t pos, std::vector<DateTime>& val)
{
throw NotImplementedException("std::vector extractor must be implemented.");

View File

@@ -1,7 +1,7 @@
//
// AbstractPreparation.cpp
//
// $Id: //poco/Main/Data/src/AbstractPreparation.cpp#1 $
// $Id: //poco/Main/Data/src/AbstractPreparation.cpp#2 $
//
// Library: Data
// Package: DataCore
@@ -41,10 +41,10 @@ namespace Poco {
namespace Data {
AbstractPreparation::AbstractPreparation(Poco::UInt32 length):
_length(length),
_bulk(false)
AbstractPreparation::AbstractPreparation(AbstractPreparator* pPreparator):
_pPreparator(pPreparator)
{
poco_assert_dbg (_pPreparator);
}
@@ -53,366 +53,4 @@ AbstractPreparation::~AbstractPreparation()
}
void AbstractPreparation::prepare(std::size_t pos, std::vector<Poco::Int8>& val)
{
throw NotImplementedException("std::vector preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::deque<Poco::Int8>& val)
{
throw NotImplementedException("std::deque preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::list<Poco::Int8>& val)
{
throw NotImplementedException("std::list preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::vector<Poco::UInt8>& val)
{
throw NotImplementedException("std::vector preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::deque<Poco::UInt8>& val)
{
throw NotImplementedException("std::deque preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::list<Poco::UInt8>& val)
{
throw NotImplementedException("std::list preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::vector<Poco::Int16>& val)
{
throw NotImplementedException("std::vector preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::deque<Poco::Int16>& val)
{
throw NotImplementedException("std::deque preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::list<Poco::Int16>& val)
{
throw NotImplementedException("std::list preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::vector<Poco::UInt16>& val)
{
throw NotImplementedException("std::vector preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::deque<Poco::UInt16>& val)
{
throw NotImplementedException("std::deque preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::list<Poco::UInt16>& val)
{
throw NotImplementedException("std::list preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::vector<Poco::Int32>& val)
{
throw NotImplementedException("std::vector preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::deque<Poco::Int32>& val)
{
throw NotImplementedException("std::deque preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::list<Poco::Int32>& val)
{
throw NotImplementedException("std::list preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::vector<Poco::UInt32>& val)
{
throw NotImplementedException("std::vector preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::deque<Poco::UInt32>& val)
{
throw NotImplementedException("std::deque preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::list<Poco::UInt32>& val)
{
throw NotImplementedException("std::list preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::vector<Poco::Int64>& val)
{
throw NotImplementedException("std::vector preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::deque<Poco::Int64>& val)
{
throw NotImplementedException("std::deque preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::list<Poco::Int64>& val)
{
throw NotImplementedException("std::list preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::vector<Poco::UInt64>& val)
{
throw NotImplementedException("std::vector preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::deque<Poco::UInt64>& val)
{
throw NotImplementedException("std::deque preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::list<Poco::UInt64>& val)
{
throw NotImplementedException("std::list preparation must be implemented.");
}
#ifndef POCO_LONG_IS_64_BIT
void AbstractPreparation::prepare(std::size_t pos, std::vector<long>& val)
{
throw NotImplementedException("std::vector preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::deque<long>& val)
{
throw NotImplementedException("std::deque preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::list<long>& val)
{
throw NotImplementedException("std::list preparation must be implemented.");
}
#endif
void AbstractPreparation::prepare(std::size_t pos, std::vector<bool>& val)
{
throw NotImplementedException("std::vector preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::deque<bool>& val)
{
throw NotImplementedException("std::deque preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::list<bool>& val)
{
throw NotImplementedException("std::list preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::vector<float>& val)
{
throw NotImplementedException("std::vector preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::deque<float>& val)
{
throw NotImplementedException("std::deque preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::list<float>& val)
{
throw NotImplementedException("std::list preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::vector<double>& val)
{
throw NotImplementedException("std::vector preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::deque<double>& val)
{
throw NotImplementedException("std::deque preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::list<double>& val)
{
throw NotImplementedException("std::list preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::vector<char>& val)
{
throw NotImplementedException("std::vector preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::deque<char>& val)
{
throw NotImplementedException("std::deque preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, std::list<char>& val)
{
throw NotImplementedException("std::list preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, const std::vector<std::string>& val)
{
throw NotImplementedException("std::vector preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, const std::deque<std::string>& val)
{
throw NotImplementedException("std::deque preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, const std::list<std::string>& val)
{
throw NotImplementedException("std::list preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, const std::vector<BLOB>& val)
{
throw NotImplementedException("std::vector preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, const std::deque<BLOB>& val)
{
throw NotImplementedException("std::deque preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, const std::list<BLOB>& val)
{
throw NotImplementedException("std::list preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, const std::vector<DateTime>& val)
{
throw NotImplementedException("std::vector preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, const std::deque<DateTime>& val)
{
throw NotImplementedException("std::deque preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, const std::list<DateTime>& val)
{
throw NotImplementedException("std::list preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, const std::vector<Date>& val)
{
throw NotImplementedException("std::vector preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, const std::deque<Date>& val)
{
throw NotImplementedException("std::deque preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, const std::list<Date>& val)
{
throw NotImplementedException("std::list preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, const std::vector<Time>& val)
{
throw NotImplementedException("std::vector preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, const std::deque<Time>& val)
{
throw NotImplementedException("std::deque preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, const std::list<Time>& val)
{
throw NotImplementedException("std::list preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, const std::vector<Any>& val)
{
throw NotImplementedException("std::vector preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, const std::deque<Any>& val)
{
throw NotImplementedException("std::deque preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, const std::list<Any>& val)
{
throw NotImplementedException("std::list preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, const std::vector<Poco::Dynamic::Var>& val)
{
throw NotImplementedException("std::vector preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, const std::deque<Poco::Dynamic::Var>& val)
{
throw NotImplementedException("std::deque preparation must be implemented.");
}
void AbstractPreparation::prepare(std::size_t pos, const std::list<Poco::Dynamic::Var>& val)
{
throw NotImplementedException("std::list preparation must be implemented.");
}
} } // namespace Poco::Data

View File

@@ -0,0 +1,436 @@
//
// AbstractPreparator.cpp
//
// $Id: //poco/Main/Data/src/AbstractPreparator.cpp#1 $
//
// Library: Data
// Package: DataCore
// Module: AbstractPreparator
//
// Copyright (c) 2006, Applied Informatics Software Engineering GmbH.
// and Contributors.
//
// Permission is hereby granted, free of charge, to any person or organization
// obtaining a copy of the software and accompanying documentation covered by
// this license (the "Software") to use, reproduce, display, distribute,
// execute, and transmit the Software, and to prepare derivative works of the
// Software, and to permit third-parties to whom the Software is furnished to
// do so, all subject to the following:
//
// The copyright notices in the Software and this entire statement, including
// the above license grant, this restriction and the following disclaimer,
// must be included in all copies of the Software, in whole or in part, and
// all derivative works of the Software, unless such copies or derivative
// works are solely in the form of machine-executable object code generated by
// a source language processor.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
// SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
// FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
// ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
//
#include "Poco/Data/AbstractPreparator.h"
namespace Poco {
namespace Data {
AbstractPreparator::AbstractPreparator(Poco::UInt32 length):
_length(length),
_bulk(false)
{
}
AbstractPreparator::~AbstractPreparator()
{
}
void AbstractPreparator::prepare(std::size_t pos, std::vector<Poco::Int8>& val)
{
throw NotImplementedException("std::vector preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::deque<Poco::Int8>& val)
{
throw NotImplementedException("std::deque preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::list<Poco::Int8>& val)
{
throw NotImplementedException("std::list preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::vector<Poco::UInt8>& val)
{
throw NotImplementedException("std::vector preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::deque<Poco::UInt8>& val)
{
throw NotImplementedException("std::deque preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::list<Poco::UInt8>& val)
{
throw NotImplementedException("std::list preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::vector<Poco::Int16>& val)
{
throw NotImplementedException("std::vector preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::deque<Poco::Int16>& val)
{
throw NotImplementedException("std::deque preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::list<Poco::Int16>& val)
{
throw NotImplementedException("std::list preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::vector<Poco::UInt16>& val)
{
throw NotImplementedException("std::vector preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::deque<Poco::UInt16>& val)
{
throw NotImplementedException("std::deque preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::list<Poco::UInt16>& val)
{
throw NotImplementedException("std::list preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::vector<Poco::Int32>& val)
{
throw NotImplementedException("std::vector preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::deque<Poco::Int32>& val)
{
throw NotImplementedException("std::deque preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::list<Poco::Int32>& val)
{
throw NotImplementedException("std::list preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::vector<Poco::UInt32>& val)
{
throw NotImplementedException("std::vector preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::deque<Poco::UInt32>& val)
{
throw NotImplementedException("std::deque preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::list<Poco::UInt32>& val)
{
throw NotImplementedException("std::list preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::vector<Poco::Int64>& val)
{
throw NotImplementedException("std::vector preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::deque<Poco::Int64>& val)
{
throw NotImplementedException("std::deque preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::list<Poco::Int64>& val)
{
throw NotImplementedException("std::list preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::vector<Poco::UInt64>& val)
{
throw NotImplementedException("std::vector preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::deque<Poco::UInt64>& val)
{
throw NotImplementedException("std::deque preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::list<Poco::UInt64>& val)
{
throw NotImplementedException("std::list preparator must be implemented.");
}
#ifndef POCO_LONG_IS_64_BIT
void AbstractPreparator::prepare(std::size_t pos, std::vector<long>& val)
{
throw NotImplementedException("std::vector preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::deque<long>& val)
{
throw NotImplementedException("std::deque preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::list<long>& val)
{
throw NotImplementedException("std::list preparator must be implemented.");
}
#endif
void AbstractPreparator::prepare(std::size_t pos, std::vector<bool>& val)
{
throw NotImplementedException("std::vector preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::deque<bool>& val)
{
throw NotImplementedException("std::deque preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::list<bool>& val)
{
throw NotImplementedException("std::list preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::vector<float>& val)
{
throw NotImplementedException("std::vector preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::deque<float>& val)
{
throw NotImplementedException("std::deque preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::list<float>& val)
{
throw NotImplementedException("std::list preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::vector<double>& val)
{
throw NotImplementedException("std::vector preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::deque<double>& val)
{
throw NotImplementedException("std::deque preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::list<double>& val)
{
throw NotImplementedException("std::list preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::vector<char>& val)
{
throw NotImplementedException("std::vector preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::deque<char>& val)
{
throw NotImplementedException("std::deque preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, std::list<char>& val)
{
throw NotImplementedException("std::list preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::vector<std::string>& val)
{
throw NotImplementedException("std::vector preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::deque<std::string>& val)
{
throw NotImplementedException("std::deque preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::list<std::string>& val)
{
throw NotImplementedException("std::list preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::vector<BLOB>& val)
{
throw NotImplementedException("std::vector preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::deque<BLOB>& val)
{
throw NotImplementedException("std::deque preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::list<BLOB>& val)
{
throw NotImplementedException("std::list preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::vector<CLOB>& val)
{
throw NotImplementedException("std::vector preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::deque<CLOB>& val)
{
throw NotImplementedException("std::deque preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::list<CLOB>& val)
{
throw NotImplementedException("std::list preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::vector<DateTime>& val)
{
throw NotImplementedException("std::vector preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::deque<DateTime>& val)
{
throw NotImplementedException("std::deque preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::list<DateTime>& val)
{
throw NotImplementedException("std::list preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::vector<Date>& val)
{
throw NotImplementedException("std::vector preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::deque<Date>& val)
{
throw NotImplementedException("std::deque preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::list<Date>& val)
{
throw NotImplementedException("std::list preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::vector<Time>& val)
{
throw NotImplementedException("std::vector preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::deque<Time>& val)
{
throw NotImplementedException("std::deque preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::list<Time>& val)
{
throw NotImplementedException("std::list preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::vector<Any>& val)
{
throw NotImplementedException("std::vector preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::deque<Any>& val)
{
throw NotImplementedException("std::deque preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::list<Any>& val)
{
throw NotImplementedException("std::list preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::vector<Poco::Dynamic::Var>& val)
{
throw NotImplementedException("std::vector preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::deque<Poco::Dynamic::Var>& val)
{
throw NotImplementedException("std::deque preparator must be implemented.");
}
void AbstractPreparator::prepare(std::size_t pos, const std::list<Poco::Dynamic::Var>& val)
{
throw NotImplementedException("std::list preparator must be implemented.");
}
} } // namespace Poco::Data

View File

@@ -1,56 +0,0 @@
//
// AbstractPrepare.cpp
//
// $Id: //poco/Main/Data/src/AbstractPrepare.cpp#2 $
//
// Library: Data
// Package: DataCore
// Module: AbstractPrepare
//
// Copyright (c) 2006, Applied Informatics Software Engineering GmbH.
// and Contributors.
//
// Permission is hereby granted, free of charge, to any person or organization
// obtaining a copy of the software and accompanying documentation covered by
// this license (the "Software") to use, reproduce, display, distribute,
// execute, and transmit the Software, and to prepare derivative works of the
// Software, and to permit third-parties to whom the Software is furnished to
// do so, all subject to the following:
//
// The copyright notices in the Software and this entire statement, including
// the above license grant, this restriction and the following disclaimer,
// must be included in all copies of the Software, in whole or in part, and
// all derivative works of the Software, unless such copies or derivative
// works are solely in the form of machine-executable object code generated by
// a source language processor.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
// SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
// FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
// ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
//
#include "Poco/Data/AbstractPrepare.h"
namespace Poco {
namespace Data {
AbstractPrepare::AbstractPrepare(AbstractPreparation* pPrepare):
_pPrepare(pPrepare)
{
poco_assert_dbg (_pPrepare);
}
AbstractPrepare::~AbstractPrepare()
{
}
} } // namespace Poco::Data

View File

@@ -1,87 +0,0 @@
//
// BLOB.cpp
//
// $Id: //poco/Main/Data/src/BLOB.cpp#7 $
//
// Library: Data
// Package: DataCore
// Module: BLOB
//
// Copyright (c) 2006, Applied Informatics Software Engineering GmbH.
// and Contributors.
//
// Permission is hereby granted, free of charge, to any person or organization
// obtaining a copy of the software and accompanying documentation covered by
// this license (the "Software") to use, reproduce, display, distribute,
// execute, and transmit the Software, and to prepare derivative works of the
// Software, and to permit third-parties to whom the Software is furnished to
// do so, all subject to the following:
//
// The copyright notices in the Software and this entire statement, including
// the above license grant, this restriction and the following disclaimer,
// must be included in all copies of the Software, in whole or in part, and
// all derivative works of the Software, unless such copies or derivative
// works are solely in the form of machine-executable object code generated by
// a source language processor.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
// SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
// FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
// ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
//
#include "Poco/Data/BLOB.h"
namespace Poco {
namespace Data {
BLOB::BLOB():
_pContent(new std::vector<char>())
{
}
BLOB::BLOB(const std::vector<char>& content):
_pContent(new std::vector<char>(content))
{
}
BLOB::BLOB(const char* const pContent, std::size_t size):
_pContent(new std::vector<char>(pContent, pContent + size))
{
}
BLOB::BLOB(const std::string& content):
_pContent(new std::vector<char>(content.begin(), content.end()))
{
}
BLOB::BLOB(const BLOB& other):
_pContent(other._pContent)
{
}
BLOB::~BLOB()
{
}
BLOB& BLOB::operator = (const BLOB& other)
{
BLOB tmp(other);
swap(tmp);
return *this;
}
} } // namespace Poco::Data

View File

@@ -1,131 +0,0 @@
//
// BLOBStream.cpp
//
// $Id: //poco/Main/Data/src/BLOBStream.cpp#2 $
//
// Library: Data
// Package: DataCore
// Module: BLOBStream
//
// Copyright (c) 2006, Applied Informatics Software Engineering GmbH.
// and Contributors.
//
// Permission is hereby granted, free of charge, to any person or organization
// obtaining a copy of the software and accompanying documentation covered by
// this license (the "Software") to use, reproduce, display, distribute,
// execute, and transmit the Software, and to prepare derivative works of the
// Software, and to permit third-parties to whom the Software is furnished to
// do so, all subject to the following:
//
// The copyright notices in the Software and this entire statement, including
// the above license grant, this restriction and the following disclaimer,
// must be included in all copies of the Software, in whole or in part, and
// all derivative works of the Software, unless such copies or derivative
// works are solely in the form of machine-executable object code generated by
// a source language processor.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
// SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
// FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
// ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
//
#include "Poco/Data/BLOBStream.h"
namespace Poco {
namespace Data {
//
// BLOBStreamBuf
//
BLOBStreamBuf::BLOBStreamBuf(BLOB& blob):
_blob(blob),
_it(_blob.begin())
{
}
BLOBStreamBuf::~BLOBStreamBuf()
{
}
UnbufferedStreamBuf::int_type BLOBStreamBuf::readFromDevice()
{
if (_it != _blob.end())
return charToInt(*_it++);
else
return -1;
}
UnbufferedStreamBuf::int_type BLOBStreamBuf::writeToDevice(char c)
{
_blob._pContent->push_back(c);
return 1;
}
//
// BLOBIOS
//
BLOBIOS::BLOBIOS(BLOB& blob, openmode mode) :_buf(blob)
{
poco_ios_init(&_buf);
}
BLOBIOS::~BLOBIOS()
{
}
BLOBStreamBuf* BLOBIOS::rdbuf()
{
return &_buf;
}
//
// BLOBOutputStream
//
BLOBOutputStream::BLOBOutputStream(BLOB& blob):
BLOBIOS(blob, std::ios::out),
std::ostream(&_buf)
{
}
BLOBOutputStream::~BLOBOutputStream()
{
}
//
// BLOBInputStream
//
BLOBInputStream::BLOBInputStream(BLOB& blob):
BLOBIOS(blob, std::ios::in),
std::istream(&_buf)
{
}
BLOBInputStream::~BLOBInputStream()
{
}
} } // namespace Poco::Data

View File

@@ -118,6 +118,7 @@ Poco::Dynamic::Var RecordSet::value(std::size_t col, std::size_t row, bool useFi
case MetaColumn::FDT_DOUBLE: return value<double>(col, row, useFilter);
case MetaColumn::FDT_STRING: return value<std::string>(col, row, useFilter);
case MetaColumn::FDT_BLOB: return value<BLOB>(col, row, useFilter);
case MetaColumn::FDT_CLOB: return value<CLOB>(col, row, useFilter);
case MetaColumn::FDT_DATE: return value<Date>(col, row, useFilter);
case MetaColumn::FDT_TIME: return value<Time>(col, row, useFilter);
case MetaColumn::FDT_TIMESTAMP: return value<DateTime>(col, row);

View File

@@ -39,7 +39,7 @@
#include "Poco/Data/DataException.h"
#include "Poco/Data/AbstractBinder.h"
#include "Poco/Data/Extraction.h"
#include "Poco/Data/BLOB.h"
#include "Poco/Data/LOB.h"
#include "Poco/Data/Date.h"
#include "Poco/Data/Time.h"
#include "Poco/SharedPtr.h"