Upcoming improved loplugin:staticanonymous -> redundantstatic: connectivity
Change-Id: I959a520f240faab062ecd4f6e2658d9fc9ce709f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/97545 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
This commit is contained in:
@@ -35,7 +35,7 @@ namespace dbtools
|
||||
using namespace css::sdbc;
|
||||
using namespace css::lang;
|
||||
|
||||
static const char ACTIVE_CONNECTION_PROPERTY_NAME[] = "ActiveConnection";
|
||||
const char ACTIVE_CONNECTION_PROPERTY_NAME[] = "ActiveConnection";
|
||||
|
||||
OAutoConnectionDisposer::OAutoConnectionDisposer(const Reference< XRowSet >& _rxRowSet, const Reference< XConnection >& _rxConnection)
|
||||
:m_xRowSet( _rxRowSet )
|
||||
|
||||
@@ -152,7 +152,7 @@ namespace dbtools
|
||||
}
|
||||
|
||||
|
||||
static const sal_Int32 aDaysInMonth[12] = { 31, 28, 31, 30, 31, 30,
|
||||
const sal_Int32 aDaysInMonth[12] = { 31, 28, 31, 30, 31, 30,
|
||||
31, 31, 30, 31, 30, 31 };
|
||||
|
||||
|
||||
|
||||
@@ -41,7 +41,7 @@ void SAL_CALL OPoolTimer::onShot()
|
||||
m_pPool->invalidatePooledConnections();
|
||||
}
|
||||
|
||||
static const char TIMEOUT_NODENAME[] = "Timeout";
|
||||
const char TIMEOUT_NODENAME[] = "Timeout";
|
||||
|
||||
OConnectionPool::OConnectionPool(const Reference< XDriver >& _xDriver,
|
||||
const Reference< XInterface >& _xDriverNode,
|
||||
|
||||
@@ -49,7 +49,7 @@ struct ApiMap
|
||||
|
||||
}
|
||||
|
||||
static const ApiMap aCommonApiMap[] =
|
||||
const ApiMap aCommonApiMap[] =
|
||||
{
|
||||
SYM_MAP( eds_check_version ),
|
||||
SYM_MAP( e_contact_field_name ),
|
||||
@@ -72,7 +72,7 @@ static const ApiMap aCommonApiMap[] =
|
||||
};
|
||||
|
||||
//< 3.6 api
|
||||
static const ApiMap aOldApiMap[] =
|
||||
const ApiMap aOldApiMap[] =
|
||||
{
|
||||
SYM_MAP( e_book_get_addressbooks ),
|
||||
SYM_MAP( e_book_get_uri ),
|
||||
@@ -85,7 +85,7 @@ static const ApiMap aOldApiMap[] =
|
||||
};
|
||||
|
||||
//>= 3.6 api
|
||||
static const ApiMap aNewApiMap[] =
|
||||
const ApiMap aNewApiMap[] =
|
||||
{
|
||||
SYM_MAP( e_source_registry_list_sources ),
|
||||
SYM_MAP( e_source_registry_new_sync ),
|
||||
@@ -102,13 +102,13 @@ static const ApiMap aNewApiMap[] =
|
||||
};
|
||||
|
||||
//== indirect read access (3.6 only)
|
||||
static const ApiMap aClientApiMap36[] =
|
||||
const ApiMap aClientApiMap36[] =
|
||||
{
|
||||
SYM_MAP( e_book_client_new )
|
||||
};
|
||||
|
||||
//>= direct read access API (>= 3.8)
|
||||
static const ApiMap aClientApiMap38[] =
|
||||
const ApiMap aClientApiMap38[] =
|
||||
{
|
||||
SYM_MAP( e_book_client_connect_direct_sync )
|
||||
};
|
||||
|
||||
@@ -46,10 +46,10 @@ namespace
|
||||
|
||||
namespace connectivity::evoab
|
||||
{
|
||||
static sal_Int32 const s_nCOLUMN_SIZE = 256;
|
||||
static sal_Int32 const s_nDECIMAL_DIGITS = 0;
|
||||
static sal_Int32 const s_nNULLABLE = 1;
|
||||
static sal_Int32 const s_nCHAR_OCTET_LENGTH = 65535;
|
||||
sal_Int32 const s_nCOLUMN_SIZE = 256;
|
||||
sal_Int32 const s_nDECIMAL_DIGITS = 0;
|
||||
sal_Int32 const s_nNULLABLE = 1;
|
||||
sal_Int32 const s_nCHAR_OCTET_LENGTH = 65535;
|
||||
|
||||
static ColumnProperty **pFields=nullptr;
|
||||
static guint nFields = 0;
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
using namespace connectivity;
|
||||
using namespace connectivity::file;
|
||||
|
||||
static const double fPi = 3.14159265358979323846;
|
||||
const double fPi = 3.14159265358979323846;
|
||||
|
||||
ORowSetValue OOp_Abs::operate(const ORowSetValue& lhs) const
|
||||
{
|
||||
|
||||
@@ -72,11 +72,11 @@ using namespace ::com::sun::star::uno;
|
||||
* Location within the .odb that an embedded .fdb will be stored.
|
||||
* Only relevant for embedded dbs.
|
||||
*/
|
||||
static const OUStringLiteral our_sFDBLocation( "firebird.fdb" );
|
||||
const OUStringLiteral our_sFDBLocation( "firebird.fdb" );
|
||||
/**
|
||||
* Older version of LO may store the database in a .fdb file
|
||||
*/
|
||||
static const OUStringLiteral our_sFBKLocation( "firebird.fbk" );
|
||||
const OUStringLiteral our_sFBKLocation( "firebird.fbk" );
|
||||
|
||||
Connection::Connection()
|
||||
: Connection_BASE(m_aMutex)
|
||||
|
||||
@@ -36,7 +36,7 @@ namespace connectivity
|
||||
// The SQL dialect in use
|
||||
// Has to be used in various isc_* calls.
|
||||
// 3: Is IB6 -- minimum required for delimited identifiers.
|
||||
static const int FIREBIRD_SQL_DIALECT = 3;
|
||||
const int FIREBIRD_SQL_DIALECT = 3;
|
||||
|
||||
/// @throws css::uno::Exception
|
||||
css::uno::Reference< css::uno::XInterface > FirebirdDriver_CreateInstance(const css::uno::Reference< css::lang::XMultiServiceFactory >& _rxFactory);
|
||||
|
||||
@@ -33,7 +33,7 @@ using namespace com::sun::star::sdbcx;
|
||||
|
||||
namespace connectivity::mork {
|
||||
|
||||
static const int defaultScope = 0x80;
|
||||
const int defaultScope = 0x80;
|
||||
|
||||
|
||||
OConnection::OConnection(MorkDriver* _pDriver)
|
||||
|
||||
@@ -26,10 +26,10 @@ using namespace com::sun::star::sdbc;
|
||||
|
||||
namespace connectivity::mork
|
||||
{
|
||||
static sal_Int32 const s_nCOLUMN_SIZE = 256;
|
||||
static sal_Int32 const s_nDECIMAL_DIGITS = 0;
|
||||
static sal_Int32 const s_nNULLABLE = 1;
|
||||
static sal_Int32 const s_nCHAR_OCTET_LENGTH = 65535;
|
||||
sal_Int32 const s_nCOLUMN_SIZE = 256;
|
||||
sal_Int32 const s_nDECIMAL_DIGITS = 0;
|
||||
sal_Int32 const s_nNULLABLE = 1;
|
||||
sal_Int32 const s_nCHAR_OCTET_LENGTH = 65535;
|
||||
}
|
||||
|
||||
ODatabaseMetaData::ODatabaseMetaData(OConnection* _pCon)
|
||||
|
||||
@@ -665,7 +665,7 @@ void OResultSet::parseParameter( const OSQLParseNode* pNode, OUString& rMatchStr
|
||||
|
||||
#define WILDCARD "%"
|
||||
#define ALT_WILDCARD "*"
|
||||
static const sal_Unicode MATCHCHAR = '_';
|
||||
const sal_Unicode MATCHCHAR = '_';
|
||||
|
||||
void OResultSet::analyseWhereClause( const OSQLParseNode* parseTree,
|
||||
MQueryExpression &queryExpression)
|
||||
|
||||
@@ -44,7 +44,7 @@ std::string const g_Empty = "";
|
||||
|
||||
const char * const MorkDictColumnMeta = "<(a=c)>";
|
||||
|
||||
static const int defaultScope_ = 0x80;
|
||||
const int defaultScope_ = 0x80;
|
||||
|
||||
MorkParser::MorkParser() :
|
||||
columns_(),
|
||||
|
||||
@@ -66,7 +66,7 @@ namespace
|
||||
// ProductRootEnvironmentVariable *must* match the constants
|
||||
// (minus 1) in offapi/com/sun/star/mozilla/MozillaProductType.idl
|
||||
// DO NOT CHANGE THE ORDER; ADD ONLY TO THE END
|
||||
static const char* DefaultProductDir[NB_PRODUCTS][NB_CANDIDATES] =
|
||||
const char* DefaultProductDir[NB_PRODUCTS][NB_CANDIDATES] =
|
||||
{
|
||||
#if defined(_WIN32)
|
||||
{ "Mozilla/SeaMonkey/", nullptr, nullptr, nullptr },
|
||||
@@ -83,7 +83,7 @@ namespace
|
||||
#endif
|
||||
};
|
||||
|
||||
static const char* ProductRootEnvironmentVariable[NB_PRODUCTS] =
|
||||
const char* ProductRootEnvironmentVariable[NB_PRODUCTS] =
|
||||
{
|
||||
"MOZILLA_PROFILE_ROOT",
|
||||
"MOZILLA_FIREFOX_PROFILE_ROOT",
|
||||
|
||||
@@ -49,13 +49,13 @@
|
||||
namespace pq_sdbc_driver
|
||||
{
|
||||
|
||||
static const sal_Int32 BASERESULTSET_CURSOR_NAME = 0;
|
||||
static const sal_Int32 BASERESULTSET_ESCAPE_PROCESSING = 1;
|
||||
static const sal_Int32 BASERESULTSET_FETCH_DIRECTION = 2;
|
||||
static const sal_Int32 BASERESULTSET_FETCH_SIZE = 3;
|
||||
static const sal_Int32 BASERESULTSET_IS_BOOKMARKABLE = 4;
|
||||
static const sal_Int32 BASERESULTSET_RESULT_SET_CONCURRENCY = 5;
|
||||
static const sal_Int32 BASERESULTSET_RESULT_SET_TYPE = 6;
|
||||
const sal_Int32 BASERESULTSET_CURSOR_NAME = 0;
|
||||
const sal_Int32 BASERESULTSET_ESCAPE_PROCESSING = 1;
|
||||
const sal_Int32 BASERESULTSET_FETCH_DIRECTION = 2;
|
||||
const sal_Int32 BASERESULTSET_FETCH_SIZE = 3;
|
||||
const sal_Int32 BASERESULTSET_IS_BOOKMARKABLE = 4;
|
||||
const sal_Int32 BASERESULTSET_RESULT_SET_CONCURRENCY = 5;
|
||||
const sal_Int32 BASERESULTSET_RESULT_SET_TYPE = 6;
|
||||
|
||||
#define BASERESULTSET_SIZE 7
|
||||
|
||||
|
||||
@@ -584,7 +584,7 @@ static Reference< XInterface > ConnectionCreateInstance(
|
||||
} // end namespace
|
||||
|
||||
|
||||
static const struct cppu::ImplementationEntry g_entries[] =
|
||||
const struct cppu::ImplementationEntry g_entries[] =
|
||||
{
|
||||
{
|
||||
pq_sdbc_driver::ConnectionCreateInstance, pq_sdbc_driver::ConnectionGetImplementationName,
|
||||
|
||||
@@ -261,7 +261,7 @@ void OOneInstanceComponentFactory::disposing()
|
||||
|
||||
}
|
||||
|
||||
static const struct cppu::ImplementationEntry g_entries[] =
|
||||
const struct cppu::ImplementationEntry g_entries[] =
|
||||
{
|
||||
{
|
||||
pq_sdbc_driver::DriverCreateInstance, pq_sdbc_driver::DriverGetImplementationName,
|
||||
|
||||
@@ -52,15 +52,15 @@
|
||||
namespace pq_sdbc_driver
|
||||
{
|
||||
|
||||
static const sal_Int32 PREPARED_STATEMENT_CURSOR_NAME = 0;
|
||||
static const sal_Int32 PREPARED_STATEMENT_ESCAPE_PROCESSING = 1;
|
||||
static const sal_Int32 PREPARED_STATEMENT_FETCH_DIRECTION = 2;
|
||||
static const sal_Int32 PREPARED_STATEMENT_FETCH_SIZE = 3;
|
||||
static const sal_Int32 PREPARED_STATEMENT_MAX_FIELD_SIZE = 4;
|
||||
static const sal_Int32 PREPARED_STATEMENT_MAX_ROWS = 5;
|
||||
static const sal_Int32 PREPARED_STATEMENT_QUERY_TIME_OUT = 6;
|
||||
static const sal_Int32 PREPARED_STATEMENT_RESULT_SET_CONCURRENCY = 7;
|
||||
static const sal_Int32 PREPARED_STATEMENT_RESULT_SET_TYPE = 8;
|
||||
const sal_Int32 PREPARED_STATEMENT_CURSOR_NAME = 0;
|
||||
const sal_Int32 PREPARED_STATEMENT_ESCAPE_PROCESSING = 1;
|
||||
const sal_Int32 PREPARED_STATEMENT_FETCH_DIRECTION = 2;
|
||||
const sal_Int32 PREPARED_STATEMENT_FETCH_SIZE = 3;
|
||||
const sal_Int32 PREPARED_STATEMENT_MAX_FIELD_SIZE = 4;
|
||||
const sal_Int32 PREPARED_STATEMENT_MAX_ROWS = 5;
|
||||
const sal_Int32 PREPARED_STATEMENT_QUERY_TIME_OUT = 6;
|
||||
const sal_Int32 PREPARED_STATEMENT_RESULT_SET_CONCURRENCY = 7;
|
||||
const sal_Int32 PREPARED_STATEMENT_RESULT_SET_TYPE = 8;
|
||||
|
||||
#define PREPARED_STATEMENT_SIZE 9
|
||||
|
||||
|
||||
@@ -88,7 +88,7 @@ namespace pq_sdbc_driver
|
||||
// };
|
||||
|
||||
// is not exported by the postgres header
|
||||
const static int PQ_VARHDRSZ = sizeof( sal_Int32 );
|
||||
const int PQ_VARHDRSZ = sizeof( sal_Int32 );
|
||||
|
||||
static void extractPrecisionAndScale( sal_Int32 atttypmod, sal_Int32 *precision, sal_Int32 *scale )
|
||||
{
|
||||
|
||||
@@ -50,15 +50,15 @@
|
||||
namespace pq_sdbc_driver
|
||||
{
|
||||
|
||||
static const sal_Int32 STATEMENT_CURSOR_NAME = 0;
|
||||
static const sal_Int32 STATEMENT_ESCAPE_PROCESSING = 1;
|
||||
static const sal_Int32 STATEMENT_FETCH_DIRECTION = 2;
|
||||
static const sal_Int32 STATEMENT_FETCH_SIZE = 3;
|
||||
static const sal_Int32 STATEMENT_MAX_FIELD_SIZE = 4;
|
||||
static const sal_Int32 STATEMENT_MAX_ROWS = 5;
|
||||
static const sal_Int32 STATEMENT_QUERY_TIME_OUT = 6;
|
||||
static const sal_Int32 STATEMENT_RESULT_SET_CONCURRENCY = 7;
|
||||
static const sal_Int32 STATEMENT_RESULT_SET_TYPE = 8;
|
||||
const sal_Int32 STATEMENT_CURSOR_NAME = 0;
|
||||
const sal_Int32 STATEMENT_ESCAPE_PROCESSING = 1;
|
||||
const sal_Int32 STATEMENT_FETCH_DIRECTION = 2;
|
||||
const sal_Int32 STATEMENT_FETCH_SIZE = 3;
|
||||
const sal_Int32 STATEMENT_MAX_FIELD_SIZE = 4;
|
||||
const sal_Int32 STATEMENT_MAX_ROWS = 5;
|
||||
const sal_Int32 STATEMENT_QUERY_TIME_OUT = 6;
|
||||
const sal_Int32 STATEMENT_RESULT_SET_CONCURRENCY = 7;
|
||||
const sal_Int32 STATEMENT_RESULT_SET_TYPE = 8;
|
||||
|
||||
#define STATEMENT_SIZE 9
|
||||
|
||||
|
||||
@@ -128,11 +128,11 @@ struct ReflectionImplementations
|
||||
struct ImplementationStatics resultSet;
|
||||
};
|
||||
|
||||
static const sal_Int32 TABLE_INDEX_CATALOG = 0;
|
||||
static const sal_Int32 TABLE_INDEX_SCHEMA = 1;
|
||||
static const sal_Int32 TABLE_INDEX_NAME = 2;
|
||||
static const sal_Int32 TABLE_INDEX_TYPE = 3;
|
||||
static const sal_Int32 TABLE_INDEX_REMARKS = 4;
|
||||
const sal_Int32 TABLE_INDEX_CATALOG = 0;
|
||||
const sal_Int32 TABLE_INDEX_SCHEMA = 1;
|
||||
const sal_Int32 TABLE_INDEX_NAME = 2;
|
||||
const sal_Int32 TABLE_INDEX_TYPE = 3;
|
||||
const sal_Int32 TABLE_INDEX_REMARKS = 4;
|
||||
|
||||
struct Statics
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user