diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2015-06-08 12:55:36 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2015-06-08 13:48:11 +0200 |
commit | 615f4b23c62b43360e7a29735bf07091bd5a73a2 (patch) | |
tree | 2da1b5663394c8fa6a5b7421f48cc2fdaf65c5b3 | |
parent | 5d6448a5131488eac3a6af16bff06140663c3db4 (diff) |
loplugin:staticmethods
Change-Id: I22af41840410ee78aee739e0dec49bb43cda874b
-rw-r--r-- | connectivity/source/parse/sqlflex.l | 10 | ||||
-rw-r--r-- | connectivity/source/parse/sqlnode.cxx | 10 | ||||
-rw-r--r-- | include/connectivity/sqlscan.hxx | 12 |
3 files changed, 16 insertions, 16 deletions
diff --git a/connectivity/source/parse/sqlflex.l b/connectivity/source/parse/sqlflex.l index 1e50927282bd..be7401059177 100644 --- a/connectivity/source/parse/sqlflex.l +++ b/connectivity/source/parse/sqlflex.l @@ -788,11 +788,11 @@ IParseContext::InternationalKeyCode OSQLScanner::getInternationalTokenID(const s return (m_bInternational) ? m_pContext->getIntlKeyCode(::rtl::OString(sToken) ) : IParseContext::KEY_NONE; } // ------------------------------------------------------------------------- -sal_Int32 OSQLScanner::GetGERRule() const { return PREDICATE_GER; } -sal_Int32 OSQLScanner::GetENGRule() const { return PREDICATE_ENG; } -sal_Int32 OSQLScanner::GetSQLRule() const { return SQL; } -sal_Int32 OSQLScanner::GetDATERule() const { return DATE; } -sal_Int32 OSQLScanner::GetSTRINGRule() const { return STRING; } +sal_Int32 OSQLScanner::GetGERRule() { return PREDICATE_GER; } +sal_Int32 OSQLScanner::GetENGRule() { return PREDICATE_ENG; } +sal_Int32 OSQLScanner::GetSQLRule() { return SQL; } +sal_Int32 OSQLScanner::GetDATERule() { return DATE; } +sal_Int32 OSQLScanner::GetSTRINGRule() { return STRING; } // ------------------------------------------------------------------------- void OSQLScanner::setScanner(bool _bNull) { diff --git a/connectivity/source/parse/sqlnode.cxx b/connectivity/source/parse/sqlnode.cxx index 5144ea8dfa70..d33502718361 100644 --- a/connectivity/source/parse/sqlnode.cxx +++ b/connectivity/source/parse/sqlnode.cxx @@ -1238,24 +1238,24 @@ OSQLParseNode* OSQLParser::predicateTree(OUString& rErrorMessage, const OUString case DataType::DATE: case DataType::TIME: case DataType::TIMESTAMP: - s_pScanner->SetRule(s_pScanner->GetDATERule()); + s_pScanner->SetRule(OSQLScanner::GetDATERule()); break; case DataType::CHAR: case DataType::VARCHAR: case DataType::LONGVARCHAR: case DataType::CLOB: - s_pScanner->SetRule(s_pScanner->GetSTRINGRule()); + s_pScanner->SetRule(OSQLScanner::GetSTRINGRule()); break; default: if ( s_xLocaleData->getLocaleItem( m_pData->aLocale ).decimalSeparator.toChar() == ',' ) - s_pScanner->SetRule(s_pScanner->GetGERRule()); + s_pScanner->SetRule(OSQLScanner::GetGERRule()); else - s_pScanner->SetRule(s_pScanner->GetENGRule()); + s_pScanner->SetRule(OSQLScanner::GetENGRule()); } } else - s_pScanner->SetRule(s_pScanner->GetSQLRule()); + s_pScanner->SetRule(OSQLScanner::GetSQLRule()); s_pScanner->prepareScan(rStatement, m_pContext, true); diff --git a/include/connectivity/sqlscan.hxx b/include/connectivity/sqlscan.hxx index 009a2d640355..1506c74dd842 100644 --- a/include/connectivity/sqlscan.hxx +++ b/include/connectivity/sqlscan.hxx @@ -64,16 +64,16 @@ namespace connectivity const OUString& getErrorMessage() const {return m_sErrorMessage;} OString getStatement() const { return m_sStatement; } - sal_Int32 SQLlex(); + static sal_Int32 SQLlex(); // set this as scanner for flex void setScanner(bool _bNull=false); // rules settings void SetRule(sal_Int32 nRule) {m_nRule = nRule;} - sal_Int32 GetGERRule() const; - sal_Int32 GetENGRule() const; - sal_Int32 GetSQLRule() const; - sal_Int32 GetDATERule() const; - sal_Int32 GetSTRINGRule() const; + static sal_Int32 GetGERRule(); + static sal_Int32 GetENGRule(); + static sal_Int32 GetSQLRule(); + static sal_Int32 GetDATERule(); + static sal_Int32 GetSTRINGRule(); inline sal_Int32 GetCurrentPos() const { return m_nCurrentPos; } }; } |