sequence->vector in OCacheSet

Change-Id: I61c6486d42dbc404355809a80943885457e79384
Reviewed-on: https://gerrit.libreoffice.org/22184
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
This commit is contained in:
Noel Grandin
2016-02-07 17:53:59 +02:00
parent 678e0ea147
commit d15d523d07
2 changed files with 9 additions and 9 deletions

View File

@@ -88,12 +88,12 @@ void OCacheSet::construct( const Reference< XResultSet>& _xDriverSet,const OUSt
if ( m_xSetMetaData.is() )
{
const sal_Int32 nCount = m_xSetMetaData->getColumnCount();
m_aNullable.realloc(nCount);
m_aSignedFlags.realloc(nCount);
m_aColumnTypes.realloc(nCount);
sal_Bool* pNullableIter = m_aNullable.getArray();
sal_Bool* pSignedIter = m_aSignedFlags.getArray();
sal_Int32* pColumnIter = m_aColumnTypes.getArray();
m_aNullable.resize(nCount);
m_aSignedFlags.resize(nCount);
m_aColumnTypes.resize(nCount);
auto pNullableIter = m_aNullable.begin();
auto pSignedIter = m_aSignedFlags.begin();
auto pColumnIter = m_aColumnTypes.begin();
for (sal_Int32 i=1; i <= nCount; ++i,++pSignedIter,++pColumnIter,++pNullableIter)
{
*pNullableIter = m_xSetMetaData->isNullable(i) != ColumnValue::NO_NULLS;

View File

@@ -44,9 +44,9 @@ namespace dbaccess
css::uno::Reference< css::sdbc::XResultSetMetaData> m_xSetMetaData;
css::uno::Reference< css::sdbc::XConnection> m_xConnection;
css::uno::Sequence<sal_Bool> m_aNullable;
css::uno::Sequence<sal_Bool> m_aSignedFlags;
css::uno::Sequence<sal_Int32> m_aColumnTypes;
std::vector<bool> m_aNullable;
std::vector<bool> m_aSignedFlags;
std::vector<sal_Int32> m_aColumnTypes;
OUString m_aComposedTableName;
sal_Int32 m_nMaxRows;
bool m_bInserted;