summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2015-07-14 14:04:41 +0200
committerNoel Grandin <noelgrandin@gmail.com>2015-07-15 07:45:23 +0000
commit82da70787ac12ec9d5791eeac6b48535737ad5b3 (patch)
tree7fd1a4cdbfcdb83549a294b39d0c918f467c6f55
parent880e3af2b502ca4f5a1f34ad9d98b9a26dc091ed (diff)
loplugin:unusedmethods connectivity
Change-Id: Ie9f3daa49b02dddc7b56d1f5fb58a229f53d4513 Reviewed-on: https://gerrit.libreoffice.org/17043 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
-rwxr-xr-xcompilerplugins/clang/unusedmethods.py8
-rw-r--r--connectivity/source/commontools/RowFunctionParser.cxx33
-rw-r--r--connectivity/source/drivers/file/FResultSet.cxx5
-rw-r--r--connectivity/source/drivers/odbc/OResultSet.cxx5
-rw-r--r--connectivity/source/inc/AutoRetrievingBase.hxx1
-rw-r--r--connectivity/source/inc/RowFunctionParser.hxx9
-rw-r--r--connectivity/source/inc/TKeyValue.hxx1
-rw-r--r--connectivity/source/inc/TResultSetHelper.hxx1
-rw-r--r--connectivity/source/inc/TSkipDeletedSet.hxx5
-rw-r--r--connectivity/source/inc/TSortIndex.hxx7
-rw-r--r--connectivity/source/inc/file/FResultSet.hxx1
-rw-r--r--connectivity/source/inc/odbc/OResultSet.hxx1
-rw-r--r--connectivity/source/sdbcx/VCollection.cxx5
-rw-r--r--include/connectivity/FValue.hxx1
-rw-r--r--include/connectivity/TKeys.hxx1
-rw-r--r--include/connectivity/dbexception.hxx4
-rw-r--r--include/connectivity/sdbcx/VCollection.hxx9
-rw-r--r--include/connectivity/sdbcx/VDescriptor.hxx1
18 files changed, 10 insertions, 88 deletions
diff --git a/compilerplugins/clang/unusedmethods.py b/compilerplugins/clang/unusedmethods.py
index 1d4208cfb376..32a10850b484 100755
--- a/compilerplugins/clang/unusedmethods.py
+++ b/compilerplugins/clang/unusedmethods.py
@@ -25,6 +25,9 @@ exclusionSet = set([
"_Bool unoidl::detail::SourceProviderInterfaceTypeEntityPad::addDirectMember(int,void *,struct unoidl::detail::SourceProviderScannerData *,const class rtl::OUString &)",
"_Bool unoidl::detail::SourceProviderInterfaceTypeEntityPad::addOptionalBaseMembers(int,void *,struct unoidl::detail::SourceProviderScannerData *,const class rtl::OUString &,const class rtl::Reference<class unoidl::InterfaceTypeEntity> &)",
"void unoidl::detail::SourceProviderScannerData::setSource(const void *,unsigned long)",
+ "enum connectivity::IParseContext::InternationalKeyCode connectivity::IParseContext::getIntlKeyCode(const class rtl::OString &) const",
+ "void connectivity::OSQLParser::error(const char *)",
+ "void connectivity::OSQLParseNode::insert(unsigned int,class connectivity::OSQLParseNode *)"
# TODO track instantiations of template class constructors
"void comphelper::IEventProcessor::release()",
"void SotMutexHolder::acquire()",
@@ -46,6 +49,11 @@ exclusionSet = set([
"int PhysicalFontFace::GetWidth() const",
"void PhysicalFontFace::SetBitmapSize(int,int)",
"_Bool SalObject::IsEraseBackgroundEnabled()",
+ "const class rtl::OUString & connectivity::OColumn::getCatalogName() const",
+ "const class rtl::OUString & connectivity::OColumn::getSchemaName() const",
+ "_Bool connectivity::OColumn::isDefinitelyWritable() const",
+ "_Bool connectivity::OColumn::isReadOnly() const",
+ "_Bool connectivity::OColumn::isWritable() const",
# instantiated from templates, not sure why it is not being picked up
"class basegfx::B2DPolygon OutputDevice::PixelToLogic(const class basegfx::B2DPolygon &,const class MapMode &) const",
# only used by OSX build
diff --git a/connectivity/source/commontools/RowFunctionParser.cxx b/connectivity/source/commontools/RowFunctionParser.cxx
index b6045c479bba..4435efb7f795 100644
--- a/connectivity/source/commontools/RowFunctionParser.cxx
+++ b/connectivity/source/commontools/RowFunctionParser.cxx
@@ -69,15 +69,6 @@ public:
virtual void fill(const ODatabaseMetaDataResultSet::ORow& /*_aRow*/ ) const SAL_OVERRIDE
{
}
- virtual ExpressionFunct getType() const SAL_OVERRIDE
- {
- return FUNC_CONST;
- }
- virtual ODatabaseMetaDataResultSet::ORow fillNode( std::vector< RowEquation >& /*rEquations*/, ExpressionNode* /* pOptionalArg */, sal_uInt32 /* nFlags */ ) SAL_OVERRIDE
- {
- ODatabaseMetaDataResultSet::ORow aRet;
- return aRet;
- }
};
@@ -128,15 +119,6 @@ public:
break;
}
}
- virtual ExpressionFunct getType() const SAL_OVERRIDE
- {
- return meFunct;
- }
- virtual ODatabaseMetaDataResultSet::ORow fillNode( std::vector< RowEquation >& /*rEquations*/, ExpressionNode* /*pOptionalArg*/, sal_uInt32 /*nFlags*/ ) SAL_OVERRIDE
- {
- ODatabaseMetaDataResultSet::ORow aRet;
- return aRet;
- }
};
@@ -243,12 +225,10 @@ public:
*/
class UnaryFunctionExpression : public ExpressionNode
{
- const ExpressionFunct meFunct;
ExpressionNodeSharedPtr mpArg;
public:
- UnaryFunctionExpression( const ExpressionFunct eFunct, const ExpressionNodeSharedPtr& rArg ) :
- meFunct( eFunct ),
+ UnaryFunctionExpression( const ExpressionNodeSharedPtr& rArg ) :
mpArg( rArg )
{
}
@@ -259,15 +239,6 @@ public:
virtual void fill(const ODatabaseMetaDataResultSet::ORow& /*_aRow*/ ) const SAL_OVERRIDE
{
}
- virtual ExpressionFunct getType() const SAL_OVERRIDE
- {
- return meFunct;
- }
- virtual ODatabaseMetaDataResultSet::ORow fillNode( std::vector< RowEquation >& /*rEquations*/, ExpressionNode* /* pOptionalArg */, sal_uInt32 /* nFlags */ ) SAL_OVERRIDE
- {
- ODatabaseMetaDataResultSet::ORow aRet;
- return aRet;
- }
};
class UnaryFunctionFunctor
@@ -294,7 +265,7 @@ public :
ExpressionNodeSharedPtr pArg( rNodeStack.top() );
rNodeStack.pop();
- rNodeStack.push( ExpressionNodeSharedPtr( new UnaryFunctionExpression( meFunct, pArg ) ) );
+ rNodeStack.push( ExpressionNodeSharedPtr( new UnaryFunctionExpression( pArg ) ) );
}
};
diff --git a/connectivity/source/drivers/file/FResultSet.cxx b/connectivity/source/drivers/file/FResultSet.cxx
index 53ee36263381..12023b985d22 100644
--- a/connectivity/source/drivers/file/FResultSet.cxx
+++ b/connectivity/source/drivers/file/FResultSet.cxx
@@ -1622,11 +1622,6 @@ sal_Int32 OResultSet::getDriverPos() const
return (m_aRow->get())[0]->getValue();
}
-bool OResultSet::deletedVisible() const
-{
- return m_bShowDeleted;
-}
-
bool OResultSet::isRowDeleted() const
{
return m_aRow->isDeleted();
diff --git a/connectivity/source/drivers/odbc/OResultSet.cxx b/connectivity/source/drivers/odbc/OResultSet.cxx
index 260f0a6f02c2..bd78ac57cdea 100644
--- a/connectivity/source/drivers/odbc/OResultSet.cxx
+++ b/connectivity/source/drivers/odbc/OResultSet.cxx
@@ -1765,11 +1765,6 @@ sal_Int32 OResultSet::getDriverPos() const
return nValue ? nValue : m_nRowPos;
}
-bool OResultSet::deletedVisible() const
-{
- return false;
-}
-
bool OResultSet::isRowDeleted() const
{
return m_pRowStatusArray[0] == SQL_ROW_DELETED;
diff --git a/connectivity/source/inc/AutoRetrievingBase.hxx b/connectivity/source/inc/AutoRetrievingBase.hxx
index c1e243135e95..74be60cb88a2 100644
--- a/connectivity/source/inc/AutoRetrievingBase.hxx
+++ b/connectivity/source/inc/AutoRetrievingBase.hxx
@@ -36,7 +36,6 @@ namespace connectivity
inline void setAutoRetrievingStatement(const OUString& _sStmt) { m_sGeneratedValueStatement = _sStmt; }
public:
inline bool isAutoRetrievingEnabled() const { return m_bAutoRetrievingEnabled; }
- inline const OUString& getAutoRetrievingStatement() const { return m_sGeneratedValueStatement; }
/** transform the statement to query for auto generated values
@param _sInsertStatement
diff --git a/connectivity/source/inc/RowFunctionParser.hxx b/connectivity/source/inc/RowFunctionParser.hxx
index 64d07e516c89..86c769125bbf 100644
--- a/connectivity/source/inc/RowFunctionParser.hxx
+++ b/connectivity/source/inc/RowFunctionParser.hxx
@@ -66,15 +66,6 @@ public:
virtual ORowSetValueDecoratorRef evaluate(const ODatabaseMetaDataResultSet::ORow& _aRow ) const = 0;
virtual void fill(const ODatabaseMetaDataResultSet::ORow& _aRow ) const = 0;
-
- /** Operator to retrieve the type of expression node
- */
- virtual ExpressionFunct getType() const = 0;
-
- /** Operator to retrieve the ms version of expression
- */
- virtual ODatabaseMetaDataResultSet::ORow fillNode(
- std::vector< RowEquation >& rEquations, ExpressionNode* pOptionalArg, sal_uInt32 nFlags ) = 0;
};
typedef ::boost::shared_ptr< ExpressionNode > ExpressionNodeSharedPtr;
diff --git a/connectivity/source/inc/TKeyValue.hxx b/connectivity/source/inc/TKeyValue.hxx
index 161d475fd731..e308b91a278d 100644
--- a/connectivity/source/inc/TKeyValue.hxx
+++ b/connectivity/source/inc/TKeyValue.hxx
@@ -52,7 +52,6 @@ namespace connectivity
{
m_aKeys.push_back(_aValueRef);
}
- inline void setValue(sal_Int32 nVal) { m_nValue = nVal; }
OUString getKeyString(::std::vector<ORowSetValueDecoratorRef>::size_type i) const
{
diff --git a/connectivity/source/inc/TResultSetHelper.hxx b/connectivity/source/inc/TResultSetHelper.hxx
index 0bc4f914983b..e6c0efd9c97f 100644
--- a/connectivity/source/inc/TResultSetHelper.hxx
+++ b/connectivity/source/inc/TResultSetHelper.hxx
@@ -42,7 +42,6 @@ namespace connectivity
public:
virtual bool move(Movement _eCursorPosition, sal_Int32 _nOffset, bool _bRetrieveData) = 0;
virtual sal_Int32 getDriverPos() const = 0;
- virtual bool deletedVisible() const = 0;
virtual bool isRowDeleted() const = 0;
protected:
diff --git a/connectivity/source/inc/TSkipDeletedSet.hxx b/connectivity/source/inc/TSkipDeletedSet.hxx
index 98ba098efb51..09f86528d598 100644
--- a/connectivity/source/inc/TSkipDeletedSet.hxx
+++ b/connectivity/source/inc/TSkipDeletedSet.hxx
@@ -85,11 +85,6 @@ namespace connectivity
sal_Int32 _nPos the logical position
*/
void deletePosition(sal_Int32 _nPos);
- /**
- getLastPosition returns the last position
- @return the last position
- */
- inline sal_Int32 getLastPosition() const { return m_aBookmarksPositions.size(); }
inline void SetDeletedVisible(bool _bDeletedVisible) { m_bDeletedVisible = _bDeletedVisible; }
};
}
diff --git a/connectivity/source/inc/TSortIndex.hxx b/connectivity/source/inc/TSortIndex.hxx
index 6f2acdc01f90..84fe2746f496 100644
--- a/connectivity/source/inc/TSortIndex.hxx
+++ b/connectivity/source/inc/TSortIndex.hxx
@@ -92,13 +92,6 @@ namespace connectivity
*/
::rtl::Reference<OKeySet> CreateKeySet();
-
-
- // look at the name
- bool IsFrozen() const { return m_bFrozen; }
- // returns the current size of the keyvalues
- size_t Count() const { return m_aKeyValues.size(); }
-
inline const ::std::vector<OKeyType>& getKeyType() const { return m_aKeyType; }
inline TAscendingOrder getAscending(::std::vector<TAscendingOrder>::size_type _nPos) const { return m_aAscending[_nPos]; }
diff --git a/connectivity/source/inc/file/FResultSet.hxx b/connectivity/source/inc/file/FResultSet.hxx
index 0eec7e303c1b..74d1d195f757 100644
--- a/connectivity/source/inc/file/FResultSet.hxx
+++ b/connectivity/source/inc/file/FResultSet.hxx
@@ -299,7 +299,6 @@ namespace connectivity
// IResultSetHelper
virtual bool move(IResultSetHelper::Movement _eCursorPosition, sal_Int32 _nOffset, bool _bRetrieveData) SAL_OVERRIDE;
virtual sal_Int32 getDriverPos() const SAL_OVERRIDE;
- virtual bool deletedVisible() const SAL_OVERRIDE;
virtual bool isRowDeleted() const SAL_OVERRIDE;
};
diff --git a/connectivity/source/inc/odbc/OResultSet.hxx b/connectivity/source/inc/odbc/OResultSet.hxx
index a501a70f936f..dabc759923bc 100644
--- a/connectivity/source/inc/odbc/OResultSet.hxx
+++ b/connectivity/source/inc/odbc/OResultSet.hxx
@@ -332,7 +332,6 @@ namespace connectivity
// IResultSetHelper
virtual bool move(IResultSetHelper::Movement _eCursorPosition, sal_Int32 _nOffset, bool _bRetrieveData) SAL_OVERRIDE;
virtual sal_Int32 getDriverPos() const SAL_OVERRIDE;
- virtual bool deletedVisible() const SAL_OVERRIDE;
virtual bool isRowDeleted() const SAL_OVERRIDE;
protected:
diff --git a/connectivity/source/sdbcx/VCollection.cxx b/connectivity/source/sdbcx/VCollection.cxx
index 8f430d86e111..b92b17131986 100644
--- a/connectivity/source/sdbcx/VCollection.cxx
+++ b/connectivity/source/sdbcx/VCollection.cxx
@@ -63,11 +63,6 @@ namespace
{
}
- virtual void reserve(size_t nLength) SAL_OVERRIDE
- {
- m_aElements.reserve(nLength);
- }
-
virtual bool exists(const OUString& _sName ) SAL_OVERRIDE
{
return m_aNameMap.find(_sName) != m_aNameMap.end();
diff --git a/include/connectivity/FValue.hxx b/include/connectivity/FValue.hxx
index 658e3394fd94..ebb228cfa7a2 100644
--- a/include/connectivity/FValue.hxx
+++ b/include/connectivity/FValue.hxx
@@ -387,7 +387,6 @@ namespace connectivity
void setTypeKind(sal_Int32 _eType);
// before calling one of this methods, be sure that the value is not null
- void* getValue() const { OSL_ENSURE(m_bBound,"Value is not bound!");return m_aValue.m_pValue; }
bool getBool() const;
sal_Int8 getInt8() const;
diff --git a/include/connectivity/TKeys.hxx b/include/connectivity/TKeys.hxx
index 0930ade12549..e70a1833468a 100644
--- a/include/connectivity/TKeys.hxx
+++ b/include/connectivity/TKeys.hxx
@@ -45,7 +45,6 @@ namespace connectivity
::osl::Mutex& _rMutex,
const TStringVector& _rVector
);
- inline OTableHelper* getTable() const { return m_pTable; }
static void cloneDescriptorColumns(
const sdbcx::ObjectType& _rSourceDescriptor,
diff --git a/include/connectivity/dbexception.hxx b/include/connectivity/dbexception.hxx
index c93371618344..5afd23aaa62c 100644
--- a/include/connectivity/dbexception.hxx
+++ b/include/connectivity/dbexception.hxx
@@ -179,10 +179,6 @@ public:
*/
bool hasMoreElements() const { return ( m_pCurrent != NULL ); }
- /** returns the type of the current element in the exception chain
- */
- SQLExceptionInfo::TYPE currentType() const { return m_eCurrentType; }
-
/** retrieves the current element in the chain, or <NULL/> if the chain has been completely
traveled.
*/
diff --git a/include/connectivity/sdbcx/VCollection.hxx b/include/connectivity/sdbcx/VCollection.hxx
index 06a68f065a8c..b056ddd92459 100644
--- a/include/connectivity/sdbcx/VCollection.hxx
+++ b/include/connectivity/sdbcx/VCollection.hxx
@@ -64,7 +64,6 @@ namespace connectivity
{
public:
virtual ~IObjectCollection();
- virtual void reserve(size_t nLength) = 0;
virtual bool exists(const OUString& _sName ) = 0;
virtual bool empty() = 0;
virtual void swapAll() = 0;
@@ -161,14 +160,6 @@ namespace connectivity
*/
void insertElement(const OUString& _sElementName,const ObjectType& _xElement);
- /** return the name of element at index _nIndex
- */
- inline OUString getElementName(sal_Int32 _nIndex)
- {
- return m_pElements->findColumnAtIndex(_nIndex);
- }
-
-
/** return the object, if not existent it creates it.
@param _nIndex
The index of the object to create.
diff --git a/include/connectivity/sdbcx/VDescriptor.hxx b/include/connectivity/sdbcx/VDescriptor.hxx
index 4c5ae155580d..3902e818cb06 100644
--- a/include/connectivity/sdbcx/VDescriptor.hxx
+++ b/include/connectivity/sdbcx/VDescriptor.hxx
@@ -62,7 +62,6 @@ namespace connectivity
virtual ~ODescriptor();
bool isNew() const { return m_bNew; }
- bool getNew() const { return m_bNew; }
void setNew(bool _bNew);
bool isCaseSensitive() const { return m_aCase.isCaseSensitive(); }