diff options
author | Julien Nabet <serval2412@yahoo.fr> | 2019-02-10 10:23:21 +0100 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-02-10 11:19:05 +0100 |
commit | 6815354b286bbc6e686fea12fada6d4d18ffb64f (patch) | |
tree | 6ff52b7e366066f794df2a36b7a104a53351f04d /dbaccess | |
parent | 16f153228461595e3ad82c3502fcb6b07cfe6f2a (diff) |
Typo: isAggreateFunction + isNumericOrAggreateFunction
Change-Id: Ief40b8f83defb223c9f6cba4bab89486e1c73f99
Reviewed-on: https://gerrit.libreoffice.org/67605
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'dbaccess')
-rw-r--r-- | dbaccess/source/ui/inc/TableFieldDescription.hxx | 4 | ||||
-rw-r--r-- | dbaccess/source/ui/querydesign/QueryDesignView.cxx | 14 | ||||
-rw-r--r-- | dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx | 12 |
3 files changed, 15 insertions, 15 deletions
diff --git a/dbaccess/source/ui/inc/TableFieldDescription.hxx b/dbaccess/source/ui/inc/TableFieldDescription.hxx index bcef693d7ab0..8c9187f10834 100644 --- a/dbaccess/source/ui/inc/TableFieldDescription.hxx +++ b/dbaccess/source/ui/inc/TableFieldDescription.hxx @@ -109,12 +109,12 @@ namespace dbaui sal_Int32 GetFunctionType() const { return m_eFunctionType; } sal_uInt16 GetColumnId() const { return m_nColumnId;} - bool isAggreateFunction() const { return (m_eFunctionType & FKT_AGGREGATE) == FKT_AGGREGATE; } + bool isAggregateFunction() const { return (m_eFunctionType & FKT_AGGREGATE) == FKT_AGGREGATE; } bool isOtherFunction() const { return (m_eFunctionType & FKT_OTHER) == FKT_OTHER; } bool isNumeric() const { return (m_eFunctionType & FKT_NUMERIC) == FKT_NUMERIC; } bool isNoneFunction() const { return m_eFunctionType == FKT_NONE; } bool isCondition() const { return (m_eFunctionType & FKT_CONDITION) == FKT_CONDITION; } - bool isNumericOrAggreateFunction() const { return isNumeric() || isAggreateFunction(); } + bool isNumericOrAggregateFunction() const { return isNumeric() || isAggregateFunction(); } bool HasCriteria() const { diff --git a/dbaccess/source/ui/querydesign/QueryDesignView.cxx b/dbaccess/source/ui/querydesign/QueryDesignView.cxx index 3b0fec6e836d..1c50c178e733 100644 --- a/dbaccess/source/ui/querydesign/QueryDesignView.cxx +++ b/dbaccess/source/ui/querydesign/QueryDesignView.cxx @@ -659,7 +659,7 @@ namespace else aTmpStr.append(rFieldName); - if ( field->isAggreateFunction() ) + if ( field->isAggregateFunction() ) { OSL_ENSURE(!field->GetFunction().isEmpty(),"Function name must not be empty! ;-("); OUStringBuffer aTmpStr2( field->GetFunction()); @@ -671,7 +671,7 @@ namespace if (!rFieldAlias.isEmpty() && (rFieldName.toChar() != '*' || - field->isNumericOrAggreateFunction() || + field->isNumericOrAggregateFunction() || field->isOtherFunction())) { aTmpStr.append(" AS "); @@ -750,14 +750,14 @@ namespace else aWork += ::dbtools::quoteName(aQuote, aFieldName); - if ( field->isAggreateFunction() || field->IsGroupBy() ) + if ( field->isAggregateFunction() || field->IsGroupBy() ) { if (aHavingStr.isEmpty()) // no more criteria aHavingStr += "("; // bracket else aHavingStr += C_AND; - if ( field->isAggreateFunction() ) + if ( field->isAggregateFunction() ) { OSL_ENSURE(!field->GetFunction().isEmpty(),"No function name for aggregate given!"); aHavingStr += field->GetFunction() + "(" + aWork + ")"; // bracket @@ -904,7 +904,7 @@ namespace { aWorkStr += ::dbtools::quoteName(aQuote, field->GetFieldAlias()); } - else if ( field->isNumericOrAggreateFunction() ) + else if ( field->isNumericOrAggregateFunction() ) { OSL_ENSURE(!field->GetFunction().isEmpty(),"Function name cannot be empty! ;-("); aWorkStr += field->GetFunction() + "(" @@ -2916,14 +2916,14 @@ std::unique_ptr<OSQLParseNode> OQueryDesignView::getPredicateTreeFromEntry(const { // we have a function here so we have to distinguish the type of return vOUalue OUString sFunction; - if ( pEntry->isNumericOrAggreateFunction() ) + if ( pEntry->isNumericOrAggregateFunction() ) sFunction = pEntry->GetFunction().getToken(0, '('); if ( sFunction.isEmpty() ) sFunction = pEntry->GetField().getToken(0, '('); sal_Int32 nType = ::connectivity::OSQLParser::getFunctionReturnType(sFunction,&rParser.getContext()); - if ( nType == DataType::OTHER || (sFunction.isEmpty() && pEntry->isNumericOrAggreateFunction()) ) + if ( nType == DataType::OTHER || (sFunction.isEmpty() && pEntry->isNumericOrAggregateFunction()) ) { // first try the international version OUString sSql; diff --git a/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx b/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx index 276ad4f3714b..070e2ab2814f 100644 --- a/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx +++ b/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx @@ -683,7 +683,7 @@ bool OSelectionBrowseBox::saveField(OUString& _sFieldName ,OTableFieldDescRef co OUString sQuotedFullFieldName(::dbtools::quoteName( xMetaData->getIdentifierQuoteString(), _sFieldName )); OUString sFullFieldName(_sFieldName); - if ( _pEntry->isAggreateFunction() ) + if ( _pEntry->isAggregateFunction() ) { OSL_ENSURE(!_pEntry->GetFunction().isEmpty(),"No empty Function name allowed here! ;-("); sQuotedFullFieldName = _pEntry->GetFunction() + "(" + sQuotedFullFieldName + ")"; @@ -1648,7 +1648,7 @@ void OSelectionBrowseBox::AddGroupBy( const OTableFieldDescRef& rInfo ) pEntry->GetFunctionType() == rInfo->GetFunctionType() && pEntry->GetFunction() == rInfo->GetFunction()) { - if ( pEntry->isNumericOrAggreateFunction() && rInfo->IsGroupBy() ) + if ( pEntry->isNumericOrAggregateFunction() && rInfo->IsGroupBy() ) { pEntry->SetGroupBy(false); // we do want to consider that bAllFieldsSearched still true here @@ -1673,7 +1673,7 @@ void OSelectionBrowseBox::AddGroupBy( const OTableFieldDescRef& rInfo ) if (bAllFieldsSearched) { OTableFieldDescRef pTmp = InsertField(rInfo, BROWSER_INVALIDID, false, false ); - if ( pTmp->isNumericOrAggreateFunction() && rInfo->IsGroupBy() ) // the GroupBy is inherited from rInfo + if ( pTmp->isNumericOrAggregateFunction() && rInfo->IsGroupBy() ) // the GroupBy is inherited from rInfo pTmp->SetGroupBy(false); } } @@ -1723,7 +1723,7 @@ void OSelectionBrowseBox::AddCondition( const OTableFieldDescRef& rInfo, const O pEntry->GetFunction() == rInfo->GetFunction() && pEntry->IsGroupBy() == rInfo->IsGroupBy() ) { - if ( pEntry->isNumericOrAggreateFunction() && rInfo->IsGroupBy() ) + if ( pEntry->isNumericOrAggregateFunction() && rInfo->IsGroupBy() ) pEntry->SetGroupBy(false); else { @@ -1769,7 +1769,7 @@ void OSelectionBrowseBox::AddCondition( const OTableFieldDescRef& rInfo, const O else if (bAllFieldsSearched) { OTableFieldDescRef pTmp = InsertField(rInfo, BROWSER_INVALIDID, false, false ); - if ( pTmp->isNumericOrAggreateFunction() && rInfo->IsGroupBy() ) // the GroupBy was inherited from rInfo + if ( pTmp->isNumericOrAggregateFunction() && rInfo->IsGroupBy() ) // the GroupBy was inherited from rInfo pTmp->SetGroupBy(false); if ( pTmp.is() ) { @@ -2129,7 +2129,7 @@ OUString OSelectionBrowseBox::GetCellText(long nRow, sal_uInt16 nColId) const // we always show the group function at first if ( pEntry->IsGroupBy() ) aText = m_aFunctionStrings.copy(m_aFunctionStrings.lastIndexOf(';')+1); - else if ( pEntry->isNumericOrAggreateFunction() ) + else if ( pEntry->isNumericOrAggregateFunction() ) aText = pEntry->GetFunction(); break; default: |