mirror of
https://github.com/pocoproject/poco.git
synced 2025-10-24 00:49:46 +02:00
eliminate MSVC71 compiler warnings
This commit is contained in:
@@ -338,7 +338,7 @@ private:
|
|||||||
{
|
{
|
||||||
C* pData = new C;
|
C* pData = new C;
|
||||||
Column<C>* pCol = new Column<C>(mc, pData);
|
Column<C>* pCol = new Column<C>(mc, pData);
|
||||||
return new InternalExtraction<C>(*pData, pCol, currentDataSet());
|
return new InternalExtraction<C>(*pData, pCol, static_cast<Poco::UInt32>(currentDataSet()));
|
||||||
}
|
}
|
||||||
|
|
||||||
template <class C>
|
template <class C>
|
||||||
@@ -346,7 +346,10 @@ private:
|
|||||||
{
|
{
|
||||||
C* pData = new C;
|
C* pData = new C;
|
||||||
Column<C>* pCol = new Column<C>(mc, pData);
|
Column<C>* pCol = new Column<C>(mc, pData);
|
||||||
return new InternalBulkExtraction<C>(*pData, pCol, getExtractionLimit(), currentDataSet());
|
return new InternalBulkExtraction<C>(*pData,
|
||||||
|
pCol,
|
||||||
|
static_cast<Poco::UInt32>(getExtractionLimit()),
|
||||||
|
static_cast<Poco::UInt32>(currentDataSet()));
|
||||||
}
|
}
|
||||||
|
|
||||||
template <class T>
|
template <class T>
|
||||||
|
@@ -311,7 +311,7 @@ bool RecordSet::moveLast()
|
|||||||
|
|
||||||
void RecordSet::setRowFormatter(RowFormatter* pRowFormatter)
|
void RecordSet::setRowFormatter(RowFormatter* pRowFormatter)
|
||||||
{
|
{
|
||||||
pRowFormatter->setTotalRowCount(getTotalRowCount());
|
pRowFormatter->setTotalRowCount(static_cast<int>(getTotalRowCount()));
|
||||||
Statement::setRowFormatter(pRowFormatter);
|
Statement::setRowFormatter(pRowFormatter);
|
||||||
RowMap::iterator it = _rowMap.begin();
|
RowMap::iterator it = _rowMap.begin();
|
||||||
RowMap::iterator end = _rowMap.end();
|
RowMap::iterator end = _rowMap.end();
|
||||||
@@ -348,7 +348,7 @@ void RecordSet::formatValues(std::size_t offset, std::size_t length) const
|
|||||||
std::ostream& RecordSet::copy(std::ostream& os, std::size_t offset, std::size_t length) const
|
std::ostream& RecordSet::copy(std::ostream& os, std::size_t offset, std::size_t length) const
|
||||||
{
|
{
|
||||||
RowFormatter& rf = const_cast<RowFormatter&>((*_pBegin)->getFormatter());
|
RowFormatter& rf = const_cast<RowFormatter&>((*_pBegin)->getFormatter());
|
||||||
rf.setTotalRowCount(getTotalRowCount());
|
rf.setTotalRowCount(static_cast<int>(getTotalRowCount()));
|
||||||
if (RowFormatter::FORMAT_PROGRESSIVE == rf.getMode())
|
if (RowFormatter::FORMAT_PROGRESSIVE == rf.getMode())
|
||||||
{
|
{
|
||||||
os << rf.prefix();
|
os << rf.prefix();
|
||||||
|
@@ -126,18 +126,19 @@ std::size_t StatementImpl::execute(const bool& reset)
|
|||||||
|
|
||||||
void StatementImpl::assignSubTotal(bool reset)
|
void StatementImpl::assignSubTotal(bool reset)
|
||||||
{
|
{
|
||||||
|
typedef CountVec::iterator IT;
|
||||||
if (_extractors.size() == _subTotalRowCount.size())
|
if (_extractors.size() == _subTotalRowCount.size())
|
||||||
{
|
{
|
||||||
CountVec::iterator it = _subTotalRowCount.begin();
|
IT it = _subTotalRowCount.begin();
|
||||||
CountVec::iterator end = _subTotalRowCount.end();
|
IT end = _subTotalRowCount.end();
|
||||||
for (int counter = 0; it != end; ++it, ++counter)
|
for (int counter = 0; it != end; ++it, ++counter)
|
||||||
{
|
{
|
||||||
if (_extractors[counter].size())
|
if (_extractors[counter].size())
|
||||||
{
|
{
|
||||||
if (reset)
|
if (reset)
|
||||||
*it += _extractors[counter][0]->numOfRowsHandled();
|
*it += IT::value_type(_extractors[counter][0]->numOfRowsHandled());
|
||||||
else
|
else
|
||||||
*it = _extractors[counter][0]->numOfRowsHandled();
|
*it = IT::value_type(_extractors[counter][0]->numOfRowsHandled());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -434,7 +435,7 @@ void StatementImpl::removeBind(const std::string& name)
|
|||||||
|
|
||||||
std::size_t StatementImpl::columnsExtracted(int dataSet) const
|
std::size_t StatementImpl::columnsExtracted(int dataSet) const
|
||||||
{
|
{
|
||||||
if (USE_CURRENT_DATA_SET == dataSet) dataSet = _curDataSet;
|
if (USE_CURRENT_DATA_SET == dataSet) dataSet = static_cast<int>(_curDataSet);
|
||||||
if (_columnsExtracted.size() > 0)
|
if (_columnsExtracted.size() > 0)
|
||||||
{
|
{
|
||||||
poco_assert (dataSet >= 0 && dataSet < _columnsExtracted.size());
|
poco_assert (dataSet >= 0 && dataSet < _columnsExtracted.size());
|
||||||
@@ -447,7 +448,7 @@ std::size_t StatementImpl::columnsExtracted(int dataSet) const
|
|||||||
|
|
||||||
std::size_t StatementImpl::rowsExtracted(int dataSet) const
|
std::size_t StatementImpl::rowsExtracted(int dataSet) const
|
||||||
{
|
{
|
||||||
if (USE_CURRENT_DATA_SET == dataSet) dataSet = _curDataSet;
|
if (USE_CURRENT_DATA_SET == dataSet) dataSet = static_cast<int>(_curDataSet);
|
||||||
if (extractions().size() > 0)
|
if (extractions().size() > 0)
|
||||||
{
|
{
|
||||||
poco_assert (dataSet >= 0 && dataSet < _extractors.size());
|
poco_assert (dataSet >= 0 && dataSet < _extractors.size());
|
||||||
@@ -461,7 +462,7 @@ std::size_t StatementImpl::rowsExtracted(int dataSet) const
|
|||||||
|
|
||||||
std::size_t StatementImpl::subTotalRowCount(int dataSet) const
|
std::size_t StatementImpl::subTotalRowCount(int dataSet) const
|
||||||
{
|
{
|
||||||
if (USE_CURRENT_DATA_SET == dataSet) dataSet = _curDataSet;
|
if (USE_CURRENT_DATA_SET == dataSet) dataSet = static_cast<int>(_curDataSet);
|
||||||
if (_subTotalRowCount.size() > 0)
|
if (_subTotalRowCount.size() > 0)
|
||||||
{
|
{
|
||||||
poco_assert (dataSet >= 0 && dataSet < _subTotalRowCount.size());
|
poco_assert (dataSet >= 0 && dataSet < _subTotalRowCount.size());
|
||||||
|
Reference in New Issue
Block a user